home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1994-10-19 | 110.9 KB | [ONLN/HLX2] |
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary).
Confidence | Program | Detection | Match Type | Support
|
---|
10%
| dexvert
| MacBinary (archive/macBinary)
| fallback
| Supported |
100%
| file
| MacBinary II, inited, Tue Oct 4 11:00:08 1994, modified Wed Oct 19 07:57:29 1994, creator 'HLX2', type 'ONLN', 109870 bytes "HW23 FPU Operations on Quad" , at 0x1adae 3354 bytes resource
| default (weak)
| |
99%
| file
| data
| default
| |
100%
| TrID
| MacBinary 2
| default (weak)
| |
100%
| siegfried
| fmt/1762 MacBinary (II)
| default
| |
100%
| lsar
| MacBinary
| default
|
|
id metadata |
---|
key | value |
---|
macFileType | [ONLN] |
macFileCreator | [HLX2] |
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 1b 48 57 32 33 20 46 | 50 55 20 4f 70 65 72 61 |..HW23 F|PU Opera|
|00000010| 74 69 6f 6e 73 20 6f 6e | 20 51 75 61 64 00 00 00 |tions on| Quad...|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 4f 4e 4c 4e 48 4c 58 | 32 01 00 00 00 00 00 00 |.ONLNHLX|2.......|
|00000050| 00 00 00 00 01 ad 2e 00 | 00 0d 1a aa b7 1e 78 aa |........|......x.|
|00000060| ca ba 29 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |..).....|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 8a 8b 00 00 |........|........|
|00000080| 48 57 20 32 33 20 2d 20 | 46 50 55 20 4f 70 65 72 |HW 23 - |FPU Oper|
|00000090| 61 74 69 6f 6e 73 20 6f | 6e 20 4d 61 63 69 6e 74 |ations o|n Macint|
|000000a0| 6f 73 68 20 51 75 61 64 | 72 61 20 43 6f 6d 70 75 |osh Quad|ra Compu|
|000000b0| 74 65 72 73 0d 48 61 72 | 64 77 61 72 65 09 0d 52 |ters.Har|dware..R|
|000000c0| 65 76 69 73 65 64 20 62 | 79 3a 09 54 69 6d 20 44 |evised b|y:.Tim D|
|000000d0| 69 65 72 6b 73 09 53 65 | 70 74 65 6d 62 65 72 20 |ierks.Se|ptember |
|000000e0| 31 39 39 32 0d 57 72 69 | 74 74 65 6e 20 62 79 3a |1992.Wri|tten by:|
|000000f0| 09 4a 6f 6e 20 4f 6b 61 | 64 61 2c 20 53 41 4e 45 |.Jon Oka|da, SANE|
|00000100| 69 74 61 74 69 6f 6e 20 | 45 6e 67 69 6e 65 65 72 |itation |Engineer|
|00000110| 2c 20 44 54 45 09 4a 75 | 6e 65 20 31 39 39 32 0d |, DTE.Ju|ne 1992.|
|00000120| 54 68 69 73 20 54 65 63 | 68 6e 69 63 61 6c 20 4e |This Tec|hnical N|
|00000130| 6f 74 65 20 64 69 73 63 | 75 73 73 65 73 20 66 6c |ote disc|usses fl|
|00000140| 6f 61 74 69 6e 67 2d 70 | 6f 69 6e 74 20 75 6e 69 |oating-p|oint uni|
|00000150| 74 20 28 46 50 55 29 20 | 69 6e 73 74 72 75 63 74 |t (FPU) |instruct|
|00000160| 69 6f 6e 20 73 75 70 70 | 6f 72 74 20 6f 6e 20 4d |ion supp|ort on M|
|00000170| 61 63 69 6e 74 6f 73 68 | 20 51 75 61 64 72 61 20 |acintosh| Quadra |
|00000180| 70 6c 61 74 66 6f 72 6d | 73 20 77 69 74 68 20 73 |platform|s with s|
|00000190| 70 65 63 69 61 6c 20 65 | 6d 70 68 61 73 69 73 20 |pecial e|mphasis |
|000001a0| 67 69 76 65 6e 20 74 6f | 20 63 6f 6d 70 61 74 69 |given to| compati|
|000001b0| 62 69 6c 69 74 79 20 61 | 6e 64 20 70 65 72 66 6f |bility a|nd perfo|
|000001c0| 72 6d 61 6e 63 65 20 63 | 6f 6e 63 65 72 6e 73 2e |rmance c|oncerns.|
|000001d0| 0d 43 68 61 6e 67 65 73 | 20 73 69 6e 63 65 20 4a |.Changes| since J|
|000001e0| 75 6e 65 20 31 39 39 32 | 3a 20 41 64 64 65 64 20 |une 1992|: Added |
|000001f0| 77 61 72 6e 69 6e 67 20 | 74 6f 20 63 68 65 63 6b |warning |to check|
|00000200| 20 66 6f 72 20 61 6e 20 | 46 50 55 20 62 65 66 6f | for an |FPU befo|
|00000210| 72 65 20 61 74 74 65 6d | 70 74 69 6e 67 20 74 6f |re attem|pting to|
|00000220| 20 65 78 65 63 75 74 65 | 20 46 50 55 20 69 6e 73 | execute| FPU ins|
|00000230| 74 72 75 63 74 69 6f 6e | 73 2e 0d 49 6e 74 72 6f |truction|s..Intro|
|00000240| 64 75 63 74 69 6f 6e 0d | 54 68 65 20 4d 61 63 69 |duction.|The Maci|
|00000250| 6e 74 6f 73 68 20 51 75 | 61 64 72 61 20 63 6f 6d |ntosh Qu|adra com|
|00000260| 70 75 74 65 72 73 20 61 | 72 65 20 74 68 65 20 66 |puters a|re the f|
|00000270| 69 72 73 74 20 41 70 70 | 6c 65 20 70 72 6f 64 75 |irst App|le produ|
|00000280| 63 74 73 20 74 6f 20 75 | 73 65 20 74 68 65 20 4d |cts to u|se the M|
|00000290| 6f 74 6f 72 6f 6c 61 20 | 36 38 30 34 30 20 6d 69 |otorola |68040 mi|
|000002a0| 63 72 6f 70 72 6f 63 65 | 73 73 6f 72 2c 20 77 68 |croproce|ssor, wh|
|000002b0| 69 63 68 20 68 61 73 20 | 61 6e 20 6f 6e 2d 63 68 |ich has |an on-ch|
|000002c0| 69 70 20 66 6c 6f 61 74 | 69 6e 67 2d 70 6f 69 6e |ip float|ing-poin|
|000002d0| 74 20 75 6e 69 74 20 28 | 46 50 55 29 2e 20 54 68 |t unit (|FPU). Th|
|000002e0| 69 73 20 66 65 61 74 75 | 72 65 20 65 6e 61 62 6c |is featu|re enabl|
|000002f0| 65 73 20 74 68 65 20 51 | 75 61 64 72 61 20 74 6f |es the Q|uadra to|
|00000300| 20 70 65 72 66 6f 72 6d | 20 62 61 73 69 63 20 66 | perform| basic f|
|00000310| 6c 6f 61 74 69 6e 67 2d | 70 6f 69 6e 74 20 6f 70 |loating-|point op|
|00000320| 65 72 61 74 69 6f 6e 73 | 20 6d 75 63 68 20 66 61 |erations| much fa|
|00000330| 73 74 65 72 20 74 68 61 | 6e 20 61 20 4d 61 63 69 |ster tha|n a Maci|
|00000340| 6e 74 6f 73 68 20 70 6c | 61 74 66 6f 72 6d 20 74 |ntosh pl|atform t|
|00000350| 68 61 74 20 65 6d 70 6c | 6f 79 73 20 61 6e 20 4d |hat empl|oys an M|
|00000360| 43 36 38 38 38 31 2f 32 | 20 66 6c 6f 61 74 69 6e |C68881/2| floatin|
|00000370| 67 2d 70 6f 69 6e 74 20 | 63 6f 70 72 6f 63 65 73 |g-point |coproces|
|00000380| 73 6f 72 20 77 6f 72 6b | 69 6e 67 20 69 6e 20 63 |sor work|ing in c|
|00000390| 6f 6e 6a 75 6e 63 74 69 | 6f 6e 20 77 69 74 68 20 |onjuncti|on with |
|000003a0| 61 6e 20 4d 43 36 38 30 | 32 30 2f 30 33 30 20 6d |an MC680|20/030 m|
|000003b0| 69 63 72 6f 70 72 6f 63 | 65 73 73 6f 72 2e 20 54 |icroproc|essor. T|
|000003c0| 68 69 73 20 4e 6f 74 65 | 20 61 64 64 72 65 73 73 |his Note| address|
|000003d0| 65 73 20 63 6f 6d 70 61 | 74 69 62 69 6c 69 74 79 |es compa|tibility|
|000003e0| 20 61 6e 64 20 70 65 72 | 66 6f 72 6d 61 6e 63 65 | and per|formance|
|000003f0| 20 69 73 73 75 65 73 20 | 66 6f 72 20 51 75 61 64 | issues |for Quad|
|00000400| 72 61 20 63 6f 6d 70 75 | 74 65 72 73 20 65 78 65 |ra compu|ters exe|
|00000410| 63 75 74 69 6e 67 20 46 | 50 55 20 69 6e 73 74 72 |cuting F|PU instr|
|00000420| 75 63 74 69 6f 6e 73 20 | 65 69 74 68 65 72 20 70 |uctions |either p|
|00000430| 72 6f 67 72 61 6d 6d 65 | 64 20 65 78 70 6c 69 63 |rogramme|d explic|
|00000440| 69 74 6c 79 20 69 6e 20 | 61 73 73 65 6d 62 6c 79 |itly in |assembly|
|00000450| 20 6c 61 6e 67 75 61 67 | 65 20 6f 72 20 67 65 6e | languag|e or gen|
|00000460| 65 72 61 74 65 64 20 62 | 79 20 63 6f 6d 70 69 6c |erated b|y compil|
|00000470| 65 72 73 20 28 2d 6d 63 | 36 38 38 38 31 20 61 6e |ers (-mc|68881 an|
|00000480| 64 20 2d 65 6c 65 6d 73 | 38 38 31 20 6d 6f 64 65 |d -elems|881 mode|
|00000490| 73 20 66 6f 72 20 4d 50 | 57 20 63 6f 6d 70 69 6c |s for MP|W compil|
|000004a0| 65 72 73 29 2e 0d 57 68 | 69 6c 65 20 61 6c 6c 20 |ers)..Wh|ile all |
|000004b0| 63 75 72 72 65 6e 74 6c | 79 20 61 76 61 69 6c 61 |currentl|y availa|
|000004c0| 62 6c 65 20 36 38 30 34 | 30 20 70 72 6f 63 65 73 |ble 6804|0 proces|
|000004d0| 73 6f 72 73 20 68 61 76 | 65 20 61 6e 20 6f 6e 62 |sors hav|e an onb|
|000004e0| 6f 61 72 64 20 46 50 55 | 2c 20 69 74 20 69 73 20 |oard FPU|, it is |
|000004f0| 69 6d 70 6f 72 74 61 6e | 74 20 74 6f 20 75 73 65 |importan|t to use|
|00000500| 20 47 65 73 74 61 6c 74 | 20 74 6f 20 76 65 72 69 | Gestalt| to veri|
|00000510| 66 79 20 74 68 65 20 65 | 78 69 73 74 65 6e 63 65 |fy the e|xistence|
|00000520| 20 6f 66 20 61 20 66 6c | 6f 61 74 69 6e 67 2d 70 | of a fl|oating-p|
|00000530| 6f 69 6e 74 20 63 6f 70 | 72 6f 63 65 73 73 6f 72 |oint cop|rocessor|
|00000540| 20 62 65 66 6f 72 65 20 | 61 74 74 65 6d 70 74 69 | before |attempti|
|00000550| 6e 67 20 74 6f 20 75 73 | 65 20 61 6e 79 20 46 50 |ng to us|e any FP|
|00000560| 55 20 69 6e 73 74 72 75 | 63 74 69 6f 6e 73 2e 20 |U instru|ctions. |
|00000570| 4d 6f 74 6f 72 6f 6c 61 | 20 68 61 73 20 61 6e 6e |Motorola| has ann|
|00000580| 6f 75 6e 63 65 64 20 61 | 20 76 61 72 69 61 6e 74 |ounced a| variant|
|00000590| 20 6f 66 20 74 68 65 20 | 36 38 30 34 30 20 77 69 | of the |68040 wi|
|000005a0| 74 68 6f 75 74 20 61 6e | 20 46 50 55 20 75 6e 69 |thout an| FPU uni|
|000005b0| 74 3b 20 74 68 69 73 20 | 63 68 69 70 20 68 61 73 |t; this |chip has|
|000005c0| 20 6d 6f 73 74 20 6f 66 | 20 74 68 65 20 63 61 63 | most of| the cac|
|000005d0| 68 69 6e 67 20 63 68 61 | 72 61 63 74 65 72 69 73 |hing cha|racteris|
|000005e0| 74 69 63 73 20 6f 66 20 | 74 68 65 20 63 75 72 72 |tics of |the curr|
|000005f0| 65 6e 74 20 36 38 30 34 | 30 2c 20 62 75 74 20 64 |ent 6804|0, but d|
|00000600| 6f 65 73 20 6e 6f 74 20 | 73 75 70 70 6f 72 74 20 |oes not |support |
|00000610| 74 68 65 20 36 38 38 38 | 31 2f 32 20 6f 70 63 6f |the 6888|1/2 opco|
|00000620| 64 65 20 73 65 74 2e 0d | 55 6e 66 6f 72 74 75 6e |de set..|Unfortun|
|00000630| 61 74 65 6c 79 2c 20 74 | 68 65 20 46 50 55 20 63 |ately, t|he FPU c|
|00000640| 69 72 63 75 69 74 72 79 | 20 69 6e 20 74 68 65 20 |ircuitry| in the |
|00000650| 36 38 30 34 30 20 64 6f | 65 73 20 6e 6f 74 20 62 |68040 do|es not b|
|00000660| 79 20 69 74 73 65 6c 66 | 20 73 75 70 70 6f 72 74 |y itself| support|
|00000670| 20 74 68 65 20 66 75 6c | 6c 20 66 75 6e 63 74 69 | the ful|l functi|
|00000680| 6f 6e 61 6c 69 74 79 20 | 6f 66 20 74 68 65 20 4d |onality |of the M|
|00000690| 43 36 38 38 38 31 2f 32 | 2e 20 4d 6f 74 6f 72 6f |C68881/2|. Motoro|
|000006a0| 6c 61 20 68 61 73 20 70 | 72 6f 76 69 64 65 64 20 |la has p|rovided |
|000006b0| 61 20 66 6c 6f 61 74 69 | 6e 67 2d 70 6f 69 6e 74 |a floati|ng-point|
|000006c0| 20 73 6f 66 74 77 61 72 | 65 20 70 61 63 6b 61 67 | softwar|e packag|
|000006d0| 65 20 28 46 50 53 50 29 | 20 77 68 69 63 68 20 65 |e (FPSP)| which e|
|000006e0| 6d 75 6c 61 74 65 73 20 | 61 6c 6c 20 6f 66 20 74 |mulates |all of t|
|000006f0| 68 65 20 4d 43 36 38 38 | 38 31 2f 32 20 66 75 6e |he MC688|81/2 fun|
|00000700| 63 74 69 6f 6e 61 6c 69 | 74 79 20 74 68 61 74 20 |ctionali|ty that |
|00000710| 69 73 20 6e 6f 74 20 70 | 72 6f 76 69 64 65 64 20 |is not p|rovided |
|00000720| 62 79 20 74 68 65 20 36 | 38 30 34 30 2e 20 54 68 |by the 6|8040. Th|
|00000730| 69 73 20 70 61 63 6b 61 | 67 65 20 72 65 73 69 64 |is packa|ge resid|
|00000740| 65 73 20 69 6e 20 74 68 | 65 20 6f 70 65 72 61 74 |es in th|e operat|
|00000750| 69 6e 67 20 73 79 73 74 | 65 6d 20 6f 66 20 74 68 |ing syst|em of th|
|00000760| 65 20 51 75 61 64 72 61 | 2e 20 57 68 65 6e 20 74 |e Quadra|. When t|
|00000770| 68 65 20 36 38 30 34 30 | 20 72 65 71 75 69 72 65 |he 68040| require|
|00000780| 73 20 65 6d 75 6c 61 74 | 69 6f 6e 20 73 65 72 76 |s emulat|ion serv|
|00000790| 69 63 65 73 20 69 6e 20 | 74 68 65 20 63 6f 75 72 |ices in |the cour|
|000007a0| 73 65 20 6f 66 20 65 78 | 65 63 75 74 69 6e 67 20 |se of ex|ecuting |
|000007b0| 61 6e 20 46 50 55 20 69 | 6e 73 74 72 75 63 74 69 |an FPU i|nstructi|
|000007c0| 6f 6e 2c 20 69 74 20 74 | 72 61 70 73 20 74 6f 20 |on, it t|raps to |
|000007d0| 74 68 65 20 46 50 53 50 | 20 76 69 61 20 6f 6e 65 |the FPSP| via one|
|000007e0| 20 6f 66 20 73 65 76 65 | 72 61 6c 20 65 78 63 65 | of seve|ral exce|
|000007f0| 70 74 69 6f 6e 20 76 65 | 63 74 6f 72 73 2c 20 64 |ption ve|ctors, d|
|00000800| 65 70 65 6e 64 69 6e 67 | 20 6f 6e 20 74 68 65 20 |epending| on the |
|00000810| 74 79 70 65 20 6f 66 20 | 65 6d 75 6c 61 74 69 6f |type of |emulatio|
|00000820| 6e 20 74 68 61 74 20 69 | 73 20 6e 65 65 64 65 64 |n that i|s needed|
|00000830| 2e 20 54 68 65 20 63 6f | 6d 62 69 6e 61 74 69 6f |. The co|mbinatio|
|00000840| 6e 20 6f 66 20 74 68 65 | 20 36 38 30 34 30 20 61 |n of the| 68040 a|
|00000850| 6e 64 20 46 50 53 50 20 | 65 6e 61 62 6c 65 73 20 |nd FPSP |enables |
|00000860| 51 75 61 64 72 61 20 63 | 6f 6d 70 75 74 65 72 73 |Quadra c|omputers|
|00000870| 20 74 6f 20 72 75 6e 20 | 6f 6c 64 20 75 73 65 72 | to run |old user|
|00000880| 20 63 6f 64 65 20 77 69 | 74 68 6f 75 74 20 6d 6f | code wi|thout mo|
|00000890| 64 69 66 69 63 61 74 69 | 6f 6e 20 75 6e 6c 65 73 |dificati|on unles|
|000008a0| 73 20 74 68 65 20 63 6f | 64 65 20 75 73 65 73 20 |s the co|de uses |
|000008b0| 66 6c 6f 61 74 69 6e 67 | 2d 70 6f 69 6e 74 20 65 |floating|-point e|
|000008c0| 78 63 65 70 74 69 6f 6e | 20 68 61 6e 64 6c 65 72 |xception| handler|
|000008d0| 73 2e 20 0d 49 66 20 75 | 73 65 72 20 63 6f 64 65 |s. .If u|ser code|
|000008e0| 20 69 6e 63 6c 75 64 65 | 73 20 66 6c 6f 61 74 69 | include|s floati|
|000008f0| 6e 67 2d 70 6f 69 6e 74 | 20 65 78 63 65 70 74 69 |ng-point| excepti|
|00000900| 6f 6e 20 68 61 6e 64 6c | 65 72 73 2c 20 74 68 65 |on handl|ers, the|
|00000910| 20 68 61 6e 64 6c 65 72 | 73 20 6d 75 73 74 20 62 | handler|s must b|
|00000920| 65 20 6d 6f 64 69 66 69 | 65 64 20 74 6f 20 72 65 |e modifi|ed to re|
|00000930| 66 6c 65 63 74 20 74 68 | 65 20 46 53 41 56 45 20 |flect th|e FSAVE |
|00000940| 73 74 61 74 65 20 66 72 | 61 6d 65 73 20 6f 66 20 |state fr|ames of |
|00000950| 74 68 65 20 36 38 30 34 | 30 2c 20 77 68 69 63 68 |the 6804|0, which|
|00000960| 20 64 69 66 66 65 72 20 | 66 72 6f 6d 20 74 68 6f | differ |from tho|
|00000970| 73 65 20 6f 66 20 74 68 | 65 20 4d 43 36 38 38 38 |se of th|e MC6888|
|00000980| 31 2f 32 2e 20 49 6e 20 | 61 64 64 69 74 69 6f 6e |1/2. In |addition|
|00000990| 2c 20 76 65 63 74 6f 72 | 69 6e 67 20 74 6f 20 73 |, vector|ing to s|
|000009a0| 75 63 68 20 68 61 6e 64 | 6c 65 72 73 20 66 6f 72 |uch hand|lers for|
|000009b0| 20 74 68 65 20 36 38 30 | 34 30 20 6d 75 73 74 20 | the 680|40 must |
|000009c0| 62 65 20 64 6f 6e 65 20 | 77 69 74 68 20 63 61 72 |be done |with car|
|000009d0| 65 20 69 6e 20 6f 72 64 | 65 72 20 74 68 61 74 20 |e in ord|er that |
|000009e0| 65 6e 74 72 79 20 74 6f | 20 74 68 65 20 46 50 53 |entry to| the FPS|
|000009f0| 50 20 6e 6f 74 20 62 65 | 20 63 6f 6d 70 72 6f 6d |P not be| comprom|
|00000a00| 69 73 65 64 2e 0d 57 68 | 65 6e 65 76 65 72 20 74 |ised..Wh|enever t|
|00000a10| 68 65 20 36 38 30 34 30 | 20 69 6e 20 61 20 51 75 |he 68040| in a Qu|
|00000a20| 61 64 72 61 20 69 6e 76 | 6f 6b 65 73 20 74 68 65 |adra inv|okes the|
|00000a30| 20 46 50 53 50 2c 20 70 | 65 72 66 6f 72 6d 61 6e | FPSP, p|erforman|
|00000a40| 63 65 20 69 6e 65 76 69 | 74 61 62 6c 79 20 77 69 |ce inevi|tably wi|
|00000a50| 6c 6c 20 73 75 66 66 65 | 72 20 72 65 6c 61 74 69 |ll suffe|r relati|
|00000a60| 76 65 20 74 6f 20 61 6e | 20 4d 43 36 38 38 38 31 |ve to an| MC68881|
|00000a70| 2f 32 20 70 6c 61 74 66 | 6f 72 6d 20 62 65 63 61 |/2 platf|orm beca|
|00000a80| 75 73 65 20 74 68 65 20 | 73 6f 66 74 77 61 72 65 |use the |software|
|00000a90| 20 65 6d 75 6c 61 74 69 | 6f 6e 20 6f 66 20 63 6f | emulati|on of co|
|00000aa0| 6d 70 6c 65 78 20 61 6c | 67 6f 72 69 74 68 6d 73 |mplex al|gorithms|
|00000ab0| 20 69 6e 76 6f 6c 76 69 | 6e 67 20 66 6c 6f 61 74 | involvi|ng float|
|00000ac0| 69 6e 67 2d 70 6f 69 6e | 74 20 63 61 6c 63 75 6c |ing-poin|t calcul|
|00000ad0| 61 74 69 6f 6e 73 20 61 | 6e 64 20 65 78 63 65 70 |ations a|nd excep|
|00000ae0| 74 69 6f 6e 20 73 74 61 | 74 65 20 73 69 6d 70 6c |tion sta|te simpl|
|00000af0| 79 20 63 61 6e 6e 6f 74 | 20 6f 75 74 70 65 72 66 |y cannot| outperf|
|00000b00| 6f 72 6d 20 64 65 64 69 | 63 61 74 65 64 20 68 61 |orm dedi|cated ha|
|00000b10| 72 64 77 61 72 65 20 61 | 6e 64 20 6d 69 63 72 6f |rdware a|nd micro|
|00000b20| 63 6f 64 65 2e 20 49 6e | 20 61 64 64 69 74 69 6f |code. In| additio|
|00000b30| 6e 2c 20 74 68 65 20 69 | 6e 73 74 72 75 63 74 69 |n, the i|nstructi|
|00000b40| 6f 6e 20 63 61 63 68 65 | 20 6d 75 73 74 20 63 6f |on cache| must co|
|00000b50| 70 65 20 77 69 74 68 20 | 6d 61 6e 79 20 69 6e 73 |pe with |many ins|
|00000b60| 74 72 75 63 74 69 6f 6e | 73 20 6f 66 20 65 6d 75 |truction|s of emu|
|00000b70| 6c 61 74 69 6f 6e 20 63 | 6f 64 65 20 74 6f 20 61 |lation c|ode to a|
|00000b80| 63 63 6f 6d 70 6c 69 73 | 68 20 77 68 61 74 20 74 |ccomplis|h what t|
|00000b90| 68 65 20 4d 43 36 38 38 | 38 31 2f 32 20 64 6f 65 |he MC688|81/2 doe|
|00000ba0| 73 20 69 6e 20 61 20 73 | 69 6e 67 6c 65 20 46 50 |s in a s|ingle FP|
|00000bb0| 55 20 69 6e 73 74 72 75 | 63 74 69 6f 6e 2e 20 46 |U instru|ction. F|
|00000bc0| 69 6e 61 6c 6c 79 2c 20 | 46 50 53 50 20 69 6e 74 |inally, |FPSP int|
|00000bd0| 65 72 76 65 6e 74 69 6f | 6e 20 66 6c 75 73 68 65 |erventio|n flushe|
|00000be0| 73 20 74 68 65 20 46 50 | 55 20 70 69 70 65 6c 69 |s the FP|U pipeli|
|00000bf0| 6e 65 2c 20 74 68 75 73 | 20 6e 65 67 61 74 69 6e |ne, thus| negatin|
|00000c00| 67 20 61 6e 79 20 70 65 | 72 66 6f 72 6d 61 6e 63 |g any pe|rformanc|
|00000c10| 65 20 65 6e 68 61 6e 63 | 65 6d 65 6e 74 73 20 61 |e enhanc|ements a|
|00000c20| 63 68 69 65 76 61 62 6c | 65 20 74 68 72 6f 75 67 |chievabl|e throug|
|00000c30| 68 20 6f 76 65 72 6c 61 | 70 70 69 6e 67 20 65 78 |h overla|pping ex|
|00000c40| 65 63 75 74 69 6f 6e 20 | 6f 66 20 46 50 55 20 69 |ecution |of FPU i|
|00000c50| 6e 73 74 72 75 63 74 69 | 6f 6e 73 2e 0d 46 50 55 |nstructi|ons..FPU|
|00000c60| 20 49 6e 73 74 72 75 63 | 74 69 6f 6e 73 20 50 72 | Instruc|tions Pr|
|00000c70| 6f 76 69 64 65 64 20 62 | 79 20 74 68 65 20 36 38 |ovided b|y the 68|
|00000c80| 30 34 30 0d 54 68 65 20 | 66 6f 6c 6c 6f 77 69 6e |040.The |followin|
|00000c90| 67 20 46 50 55 20 69 6e | 73 74 72 75 63 74 69 6f |g FPU in|structio|
|00000ca0| 6e 73 20 61 72 65 20 73 | 75 70 70 6f 72 74 65 64 |ns are s|upported|
|00000cb0| 20 62 79 20 74 68 65 20 | 36 38 30 34 30 3a 0d 09 | by the |68040:..|
|00000cc0| 09 46 41 42 53 09 09 09 | 41 62 73 6f 6c 75 74 65 |.FABS...|Absolute|
|00000cd0| 20 76 61 6c 75 65 0d 09 | 09 46 44 41 42 53 2a 09 | value..|.FDABS*.|
|00000ce0| 09 41 62 73 6f 6c 75 74 | 65 20 76 61 6c 75 65 20 |.Absolut|e value |
|00000cf0| 72 6f 75 6e 64 65 64 20 | 74 6f 20 64 6f 75 62 6c |rounded |to doubl|
|00000d00| 65 20 70 72 65 63 69 73 | 69 6f 6e 0d 09 09 46 53 |e precis|ion...FS|
|00000d10| 41 42 53 2a 09 09 41 62 | 73 6f 6c 75 74 65 20 76 |ABS*..Ab|solute v|
|00000d20| 61 6c 75 65 20 72 6f 75 | 6e 64 65 64 20 74 6f 20 |alue rou|nded to |
|00000d30| 73 69 6e 67 6c 65 20 70 | 72 65 63 69 73 69 6f 6e |single p|recision|
|00000d40| 0d 09 09 46 41 44 44 09 | 09 09 41 64 64 69 74 69 |...FADD.|..Additi|
|00000d50| 6f 6e 0d 09 09 46 44 41 | 44 44 2a 09 09 41 64 64 |on...FDA|DD*..Add|
|00000d60| 69 74 69 6f 6e 20 72 6f | 75 6e 64 65 64 20 74 6f |ition ro|unded to|
|00000d70| 20 64 6f 75 62 6c 65 20 | 70 72 65 63 69 73 69 6f | double |precisio|
|00000d80| 6e 0d 09 09 46 53 41 44 | 44 2a 09 09 41 64 64 69 |n...FSAD|D*..Addi|
|00000d90| 74 69 6f 6e 20 72 6f 75 | 6e 64 65 64 20 74 6f 20 |tion rou|nded to |
|00000da0| 73 69 6e 67 6c 65 20 70 | 72 65 63 69 73 69 6f 6e |single p|recision|
|00000db0| 0d 09 09 46 42 63 63 2a | 09 09 42 72 61 6e 63 68 |...FBcc*|..Branch|
|00000dc0| 20 6f 6e 20 46 50 20 63 | 6f 6e 64 69 74 69 6f 6e | on FP c|ondition|
|00000dd0| 0d 09 09 46 43 4d 50 09 | 09 09 43 6f 6d 70 61 72 |...FCMP.|..Compar|
|00000de0| 69 73 6f 6e 20 28 73 65 | 74 73 20 46 50 20 63 6f |ison (se|ts FP co|
|00000df0| 6e 64 69 74 69 6f 6e 20 | 63 6f 64 65 73 29 0d 09 |ndition |codes)..|
|00000e00| 09 46 44 42 63 63 09 09 | 54 65 73 74 20 46 50 20 |.FDBcc..|Test FP |
|00000e10| 63 6f 6e 64 69 74 69 6f | 6e 2c 20 64 65 63 72 65 |conditio|n, decre|
|00000e20| 6d 65 6e 74 20 44 20 72 | 65 67 69 73 74 65 72 2c |ment D r|egister,|
|00000e30| 20 61 6e 64 20 62 72 61 | 6e 63 68 0d 09 09 46 44 | and bra|nch...FD|
|00000e40| 49 56 09 09 09 44 69 76 | 69 73 69 6f 6e 0d 09 09 |IV...Div|ision...|
|00000e50| 46 44 44 49 56 2a 09 09 | 44 69 76 69 73 69 6f 6e |FDDIV*..|Division|
|00000e60| 20 72 6f 75 6e 64 65 64 | 20 74 6f 20 64 6f 75 62 | rounded| to doub|
|00000e70| 6c 65 20 70 72 65 63 69 | 73 69 6f 6e 0d 09 09 46 |le preci|sion...F|
|00000e80| 53 44 49 56 2a 09 09 44 | 69 76 69 73 69 6f 6e 20 |SDIV*..D|ivision |
|00000e90| 72 6f 75 6e 64 65 64 20 | 74 6f 20 73 69 6e 67 6c |rounded |to singl|
|00000ea0| 65 20 70 72 65 63 69 73 | 69 6f 6e 0d 09 09 46 4d |e precis|ion...FM|
|00000eb0| 4f 56 45 09 09 4d 6f 76 | 65 20 46 50 20 64 61 74 |OVE..Mov|e FP dat|
|00000ec0| 61 20 6f 72 20 73 79 73 | 74 65 6d 20 63 6f 6e 74 |a or sys|tem cont|
|00000ed0| 72 6f 6c 20 72 65 67 69 | 73 74 65 72 0d 09 09 46 |rol regi|ster...F|
|00000ee0| 44 4d 4f 56 45 2a 09 09 | 4d 6f 76 65 20 74 6f 20 |DMOVE*..|Move to |
|00000ef0| 46 50 20 64 61 74 61 20 | 72 65 67 69 73 74 65 72 |FP data |register|
|00000f00| 20 72 6f 75 6e 64 65 64 | 20 74 6f 20 64 6f 75 62 | rounded| to doub|
|00000f10| 6c 65 20 70 72 65 63 69 | 73 69 6f 6e 0d 09 09 46 |le preci|sion...F|
|00000f20| 53 4d 4f 56 45 2a 09 09 | 4d 6f 76 65 20 74 6f 20 |SMOVE*..|Move to |
|00000f30| 46 50 20 64 61 74 61 20 | 72 65 67 69 73 74 65 72 |FP data |register|
|00000f40| 20 72 6f 75 6e 64 65 64 | 20 74 6f 20 73 69 6e 67 | rounded| to sing|
|00000f50| 6c 65 20 70 72 65 63 69 | 73 69 6f 6e 0d 09 09 46 |le preci|sion...F|
|00000f60| 4d 4f 56 45 4d 09 09 4d | 6f 76 65 20 6d 75 6c 74 |MOVEM..M|ove mult|
|00000f70| 69 70 6c 65 20 46 50 20 | 64 61 74 61 20 72 65 67 |iple FP |data reg|
|00000f80| 69 73 74 65 72 73 0d 09 | 09 46 4d 55 4c 09 09 09 |isters..|.FMUL...|
|00000f90| 4d 75 6c 74 69 70 6c 69 | 63 61 74 69 6f 6e 0d 09 |Multipli|cation..|
|00000fa0| 09 46 44 4d 55 4c 2a 09 | 09 4d 75 6c 74 69 70 6c |.FDMUL*.|.Multipl|
|00000fb0| 69 63 61 74 69 6f 6e 20 | 72 6f 75 6e 64 65 64 20 |ication |rounded |
|00000fc0| 74 6f 20 64 6f 75 62 6c | 65 20 70 72 65 63 69 73 |to doubl|e precis|
|00000fd0| 69 6f 6e 0d 09 09 46 53 | 4d 55 4c 2a 09 09 4d 75 |ion...FS|MUL*..Mu|
|00000fe0| 6c 74 69 70 6c 69 63 61 | 74 69 6f 6e 20 72 6f 75 |ltiplica|tion rou|
|00000ff0| 6e 64 65 64 20 74 6f 20 | 73 69 6e 67 6c 65 20 70 |nded to |single p|
|00001000| 72 65 63 69 73 69 6f 6e | 0d 09 09 46 4e 45 47 09 |recision|...FNEG.|
|00001010| 09 09 4e 65 67 61 74 69 | 6f 6e 0d 09 09 46 44 4e |..Negati|on...FDN|
|00001020| 45 47 2a 09 09 4e 65 67 | 61 74 69 6f 6e 20 72 6f |EG*..Neg|ation ro|
|00001030| 75 6e 64 65 64 20 74 6f | 20 64 6f 75 62 6c 65 20 |unded to| double |
|00001040| 70 72 65 63 69 73 69 6f | 6e 0d 09 09 46 53 4e 45 |precisio|n...FSNE|
|00001050| 47 2a 09 09 4e 65 67 61 | 74 69 6f 6e 20 72 6f 75 |G*..Nega|tion rou|
|00001060| 6e 64 65 64 20 74 6f 20 | 73 69 6e 67 6c 65 20 70 |nded to |single p|
|00001070| 72 65 63 69 73 69 6f 6e | 0d 09 09 46 4e 4f 50 09 |recision|...FNOP.|
|00001080| 09 09 4e 6f 20 6f 70 65 | 72 61 74 69 6f 6e 20 28 |..No ope|ration (|
|00001090| 66 6c 75 73 68 65 73 20 | 46 50 55 20 70 69 70 65 |flushes |FPU pipe|
|000010a0| 6c 69 6e 65 73 20 61 6e | 64 20 66 6f 72 63 65 73 |lines an|d forces|
|000010b0| 20 70 65 6e 64 69 6e 67 | 20 0d 09 09 09 09 09 46 | pending| ......F|
|000010c0| 50 20 65 78 63 65 70 74 | 69 6f 6e 73 29 0d 09 09 |P except|ions)...|
|000010d0| 46 52 45 53 54 4f 52 45 | a0 09 09 52 65 73 74 6f |FRESTORE|...Resto|
|000010e0| 72 65 20 69 6e 74 65 72 | 6e 61 6c 20 46 50 55 20 |re inter|nal FPU |
|000010f0| 73 74 61 74 65 20 73 61 | 76 65 64 20 62 79 20 46 |state sa|ved by F|
|00001100| 53 41 56 45 0d 09 09 46 | 53 41 56 45 a0 09 09 53 |SAVE...F|SAVE...S|
|00001110| 61 76 65 20 69 6e 74 65 | 72 6e 61 6c 20 46 50 55 |ave inte|rnal FPU|
|00001120| 20 73 74 61 74 65 0d 09 | 09 46 53 63 63 09 09 09 | state..|.FScc...|
|00001130| 53 65 74 20 62 79 74 65 | 20 69 6e 74 65 67 65 72 |Set byte| integer|
|00001140| 20 61 63 63 6f 72 64 69 | 6e 67 20 74 6f 20 46 50 | accordi|ng to FP|
|00001150| 20 63 6f 6e 64 69 74 69 | 6f 6e 0d 09 09 46 53 47 | conditi|on...FSG|
|00001160| 4c 44 49 56 09 09 53 69 | 6e 67 6c 65 20 70 72 65 |LDIV..Si|ngle pre|
|00001170| 63 69 73 69 6f 6e 20 64 | 69 76 69 73 69 6f 6e 0d |cision d|ivision.|
|00001180| 09 09 46 53 47 4c 4d 55 | 4c 09 09 53 69 6e 67 6c |..FSGLMU|L..Singl|
|00001190| 65 20 70 72 65 63 69 73 | 69 6f 6e 20 6d 75 6c 74 |e precis|ion mult|
|000011a0| 69 70 6c 79 0d 09 09 46 | 53 51 52 54 09 09 53 71 |iply...F|SQRT..Sq|
|000011b0| 75 61 72 65 20 72 6f 6f | 74 0d 09 09 46 44 53 51 |uare roo|t...FDSQ|
|000011c0| 52 54 2a 09 09 53 71 75 | 61 72 65 20 72 6f 6f 74 |RT*..Squ|are root|
|000011d0| 20 72 6f 75 6e 64 65 64 | 20 74 6f 20 64 6f 75 62 | rounded| to doub|
|000011e0| 6c 65 20 70 72 65 63 69 | 73 69 6f 6e 0d 09 09 46 |le preci|sion...F|
|000011f0| 53 53 51 52 54 2a 09 09 | 53 71 75 61 72 65 20 72 |SSQRT*..|Square r|
|00001200| 6f 6f 74 20 72 6f 75 6e | 64 65 64 20 74 6f 20 73 |oot roun|ded to s|
|00001210| 69 6e 67 6c 65 20 70 72 | 65 63 69 73 69 6f 6e 0d |ingle pr|ecision.|
|00001220| 09 09 46 53 55 42 09 09 | 09 53 75 62 74 72 61 63 |..FSUB..|.Subtrac|
|00001230| 74 69 6f 6e 0d 09 09 46 | 44 53 55 42 2a 09 09 53 |tion...F|DSUB*..S|
|00001240| 75 62 74 72 61 63 74 69 | 6f 6e 20 72 6f 75 6e 64 |ubtracti|on round|
|00001250| 65 64 20 74 6f 20 64 6f | 75 62 6c 65 20 70 72 65 |ed to do|uble pre|
|00001260| 63 69 73 69 6f 6e 0d 09 | 09 46 53 53 55 42 2a 09 |cision..|.FSSUB*.|
|00001270| 09 53 75 62 74 72 61 63 | 74 69 6f 6e 20 72 6f 75 |.Subtrac|tion rou|
|00001280| 6e 64 65 64 20 74 6f 20 | 73 69 6e 67 6c 65 20 70 |nded to |single p|
|00001290| 72 65 63 69 73 69 6f 6e | 0d 09 09 46 54 52 41 50 |recision|...FTRAP|
|000012a0| 63 63 09 09 54 72 61 70 | 20 6f 6e 20 46 50 20 63 |cc..Trap| on FP c|
|000012b0| 6f 6e 64 69 74 69 6f 6e | 0d 09 09 46 54 53 54 09 |ondition|...FTST.|
|000012c0| 09 09 54 65 73 74 20 46 | 50 20 6f 70 65 72 61 6e |..Test F|P operan|
|000012d0| 64 20 61 6e 64 20 73 65 | 74 20 46 50 20 63 6f 6e |d and se|t FP con|
|000012e0| 64 69 74 69 6f 6e 20 63 | 6f 64 65 73 0d 09 09 2a |dition c|odes...*|
|000012f0| 09 50 72 65 63 69 73 69 | 6f 6e 2d 63 6f 6e 73 74 |.Precisi|on-const|
|00001300| 72 61 69 6e 69 6e 67 20 | 6f 70 65 72 61 74 69 6f |raining |operatio|
|00001310| 6e 20 69 73 20 6e 6f 74 | 20 70 72 6f 76 69 64 65 |n is not| provide|
|00001320| 64 20 62 79 20 4d 43 36 | 38 38 38 31 2f 32 3b 20 |d by MC6|8881/2; |
|00001330| 0d 09 09 09 70 72 65 63 | 69 73 69 6f 6e 20 6f 66 |....prec|ision of|
|00001340| 20 69 6e 73 74 72 75 63 | 74 69 6f 6e 20 73 75 70 | instruc|tion sup|
|00001350| 65 72 73 65 64 65 73 20 | 74 68 61 74 20 73 65 74 |ersedes |that set|
|00001360| 20 69 6e 20 74 68 65 20 | 46 50 20 63 6f 6e 74 72 | in the |FP contr|
|00001370| 6f 6c 20 72 65 67 69 73 | 74 65 72 20 0d 09 09 09 |ol regis|ter ....|
|00001380| 28 46 50 43 52 29 2e 0d | 09 09 a0 09 50 72 69 76 |(FPCR)..|....Priv|
|00001390| 69 6c 65 67 65 64 20 69 | 6e 73 74 72 75 63 74 69 |ileged i|nstructi|
|000013a0| 6f 6e 2e 0d 50 72 6f 63 | 65 73 73 69 6e 67 20 6f |on..Proc|essing o|
|000013b0| 66 20 74 68 65 73 65 20 | 46 50 55 20 69 6e 73 74 |f these |FPU inst|
|000013c0| 72 75 63 74 69 6f 6e 73 | 20 69 73 20 75 73 75 61 |ructions| is usua|
|000013d0| 6c 6c 79 20 68 61 6e 64 | 6c 65 64 20 65 6e 74 69 |lly hand|led enti|
|000013e0| 72 65 6c 79 20 62 79 20 | 74 68 65 20 36 38 30 34 |rely by |the 6804|
|000013f0| 30 2e 20 54 68 65 20 46 | 50 53 50 20 69 73 20 69 |0. The F|PSP is i|
|00001400| 6e 76 6f 6b 65 64 20 69 | 66 20 61 6e 20 75 6e 73 |nvoked i|f an uns|
|00001410| 75 70 70 6f 72 74 65 64 | 20 64 61 74 61 20 74 79 |upported| data ty|
|00001420| 70 65 20 6f 72 20 66 6f | 72 6d 61 74 20 69 73 20 |pe or fo|rmat is |
|00001430| 69 6e 76 6f 6c 76 65 64 | 20 6f 72 20 69 66 20 61 |involved| or if a|
|00001440| 6e 20 65 78 63 65 70 74 | 69 6f 6e 61 6c 20 63 6f |n except|ional co|
|00001450| 6e 64 69 74 69 6f 6e 20 | 69 73 20 67 65 6e 65 72 |ndition |is gener|
|00001460| 61 74 65 64 20 74 68 61 | 74 20 72 65 71 75 69 72 |ated tha|t requir|
|00001470| 65 73 20 66 69 78 2d 75 | 70 20 6f 66 20 46 50 55 |es fix-u|p of FPU|
|00001480| 20 73 74 61 74 65 20 62 | 79 20 65 6d 75 6c 61 74 | state b|y emulat|
|00001490| 69 6f 6e 2e 0d 46 50 53 | 50 20 4f 76 65 72 76 69 |ion..FPS|P Overvi|
|000014a0| 65 77 0d 54 68 65 20 46 | 50 53 50 20 70 72 6f 76 |ew.The F|PSP prov|
|000014b0| 69 64 65 73 20 74 68 72 | 65 65 20 62 61 73 69 63 |ides thr|ee basic|
|000014c0| 20 65 6d 75 6c 61 74 69 | 6f 6e 20 73 65 72 76 69 | emulati|on servi|
|000014d0| 63 65 73 20 66 6f 72 20 | 74 68 65 20 36 38 30 34 |ces for |the 6804|
|000014e0| 30 2e 20 46 69 72 73 74 | 2c 20 69 74 20 65 6d 75 |0. First|, it emu|
|000014f0| 6c 61 74 65 73 20 6d 61 | 6e 79 20 4d 43 36 38 38 |lates ma|ny MC688|
|00001500| 38 31 2f 32 20 69 6e 73 | 74 72 75 63 74 69 6f 6e |81/2 ins|truction|
|00001510| 73 2c 20 69 6e 63 6c 75 | 64 69 6e 67 20 61 6c 6c |s, inclu|ding all|
|00001520| 20 74 72 61 6e 73 63 65 | 6e 64 65 6e 74 61 6c 20 | transce|ndental |
|00001530| 66 75 6e 63 74 69 6f 6e | 73 20 61 6e 64 20 73 6f |function|s and so|
|00001540| 6d 65 20 61 72 69 74 68 | 6d 65 74 69 63 20 69 6e |me arith|metic in|
|00001550| 73 74 72 75 63 74 69 6f | 6e 73 2e 20 53 65 63 6f |structio|ns. Seco|
|00001560| 6e 64 2c 20 74 68 65 20 | 46 50 53 50 20 68 61 6e |nd, the |FPSP han|
|00001570| 64 6c 65 73 20 69 6e 73 | 74 72 75 63 74 69 6f 6e |dles ins|truction|
|00001580| 73 20 74 68 61 74 20 69 | 6e 76 6f 6c 76 65 20 63 |s that i|nvolve c|
|00001590| 65 72 74 61 69 6e 20 64 | 61 74 61 20 63 6c 61 73 |ertain d|ata clas|
|000015a0| 73 65 73 20 28 75 6e 6e | 6f 72 6d 61 6c 69 7a 65 |ses (unn|ormalize|
|000015b0| 64 20 61 6e 64 20 64 65 | 6e 6f 72 6d 61 6c 20 66 |d and de|normal f|
|000015c0| 6c 6f 61 74 69 6e 67 2d | 70 6f 69 6e 74 20 6e 75 |loating-|point nu|
|000015d0| 6d 62 65 72 73 29 20 6f | 72 20 74 68 65 20 70 61 |mbers) o|r the pa|
|000015e0| 63 6b 65 64 20 64 65 63 | 69 6d 61 6c 20 64 61 74 |cked dec|imal dat|
|000015f0| 61 20 66 6f 72 6d 61 74 | 2c 20 77 68 69 63 68 20 |a format|, which |
|00001600| 61 72 65 20 6e 6f 74 20 | 73 75 70 70 6f 72 74 65 |are not |supporte|
|00001610| 64 20 62 79 20 74 68 65 | 20 36 38 30 34 30 20 68 |d by the| 68040 h|
|00001620| 61 72 64 77 61 72 65 2e | 20 46 69 6e 61 6c 6c 79 |ardware.| Finally|
|00001630| 2c 20 74 68 65 20 46 50 | 53 50 20 70 72 6f 76 69 |, the FP|SP provi|
|00001640| 64 65 73 20 65 78 63 65 | 70 74 69 6f 6e 20 68 61 |des exce|ption ha|
|00001650| 6e 64 6c 65 72 73 20 66 | 6f 72 20 63 65 72 74 61 |ndlers f|or certa|
|00001660| 69 6e 20 66 6c 6f 61 74 | 69 6e 67 2d 70 6f 69 6e |in float|ing-poin|
|00001670| 74 20 65 78 63 65 70 74 | 69 6f 6e 20 63 6f 6e 64 |t except|ion cond|
|00001680| 69 74 69 6f 6e 73 20 69 | 6e 20 6f 72 64 65 72 20 |itions i|n order |
|00001690| 74 6f 20 65 6d 75 6c 61 | 74 65 20 4d 43 36 38 38 |to emula|te MC688|
|000016a0| 38 31 2f 32 20 62 65 68 | 61 76 69 6f 72 20 77 68 |81/2 beh|avior wh|
|000016b0| 65 6e 20 75 73 65 72 20 | 74 72 61 70 73 20 61 72 |en user |traps ar|
|000016c0| 65 20 65 69 74 68 65 72 | 20 64 69 73 61 62 6c 65 |e either| disable|
|000016d0| 64 20 6f 72 20 65 6e 61 | 62 6c 65 64 2e 20 49 6e |d or ena|bled. In|
|000016e0| 20 74 68 65 20 6c 61 74 | 74 65 72 20 63 61 73 65 | the lat|ter case|
|000016f0| 2c 20 61 66 74 65 72 20 | 63 6f 6d 70 6c 65 74 69 |, after |completi|
|00001700| 6e 67 20 69 74 73 20 65 | 78 63 65 70 74 69 6f 6e |ng its e|xception|
|00001710| 20 70 72 6f 63 65 73 73 | 69 6e 67 2c 20 74 68 65 | process|ing, the|
|00001720| 20 46 50 53 50 20 70 61 | 73 73 65 73 20 63 6f 6e | FPSP pa|sses con|
|00001730| 74 72 6f 6c 20 74 6f 20 | 74 68 65 20 75 73 65 72 |trol to |the user|
|00001740| 2d 70 72 6f 76 69 64 65 | 64 20 68 61 6e 64 6c 65 |-provide|d handle|
|00001750| 72 2e 0d 4f 6e 20 4d 61 | 63 69 6e 74 6f 73 68 20 |r..On Ma|cintosh |
|00001760| 51 75 61 64 72 61 20 70 | 6c 61 74 66 6f 72 6d 73 |Quadra p|latforms|
|00001770| 20 65 78 65 63 75 74 69 | 6e 67 20 4d 43 36 38 38 | executi|ng MC688|
|00001780| 38 31 2f 32 20 69 6e 73 | 74 72 75 63 74 69 6f 6e |81/2 ins|truction|
|00001790| 73 2c 20 65 6e 74 72 79 | 20 74 6f 20 74 68 65 20 |s, entry| to the |
|000017a0| 46 50 53 50 20 6f 63 63 | 75 72 73 20 61 75 74 6f |FPSP occ|urs auto|
|000017b0| 6d 61 74 69 63 61 6c 6c | 79 20 62 79 20 74 72 61 |maticall|y by tra|
|000017c0| 70 70 69 6e 67 20 76 69 | 61 20 6f 6e 65 20 6f 66 |pping vi|a one of|
|000017d0| 20 73 65 76 65 72 61 6c | 20 6c 6f 77 2d 6d 65 6d | several| low-mem|
|000017e0| 6f 72 79 20 65 78 63 65 | 70 74 69 6f 6e 20 76 65 |ory exce|ption ve|
|000017f0| 63 74 6f 72 73 2c 20 64 | 65 70 65 6e 64 69 6e 67 |ctors, d|epending|
|00001800| 20 6f 6e 20 77 68 69 63 | 68 20 65 6d 75 6c 61 74 | on whic|h emulat|
|00001810| 69 6f 6e 20 73 65 72 76 | 69 63 65 20 69 73 20 72 |ion serv|ice is r|
|00001820| 65 71 75 69 72 65 64 2e | 20 54 68 65 20 73 79 73 |equired.| The sys|
|00001830| 74 65 6d 20 69 6e 73 74 | 61 6c 6c 73 20 74 68 65 |tem inst|alls the|
|00001840| 20 65 78 63 65 70 74 69 | 6f 6e 20 76 65 63 74 6f | excepti|on vecto|
|00001850| 72 20 65 6e 74 72 69 65 | 73 20 74 6f 20 74 68 65 |r entrie|s to the|
|00001860| 20 46 50 53 50 20 61 74 | 20 62 6f 6f 74 20 74 69 | FPSP at| boot ti|
|00001870| 6d 65 2c 20 61 6e 64 20 | 61 70 70 6c 69 63 61 74 |me, and |applicat|
|00001880| 69 6f 6e 73 20 73 68 6f | 75 6c 64 20 6e 6f 74 20 |ions sho|uld not |
|00001890| 74 61 6d 70 65 72 20 77 | 69 74 68 20 74 68 65 73 |tamper w|ith thes|
|000018a0| 65 20 76 65 63 74 6f 72 | 73 2e 20 42 65 63 61 75 |e vector|s. Becau|
|000018b0| 73 65 20 74 68 65 20 46 | 50 53 50 20 70 72 65 65 |se the F|PSP pree|
|000018c0| 6d 70 74 73 20 74 68 65 | 20 65 78 63 65 70 74 69 |mpts the| excepti|
|000018d0| 6f 6e 20 76 65 63 74 6f | 72 73 20 66 6f 72 20 63 |on vecto|rs for c|
|000018e0| 65 72 74 61 69 6e 20 75 | 73 65 72 2d 70 72 6f 76 |ertain u|ser-prov|
|000018f0| 69 64 65 64 20 68 61 6e | 64 6c 65 72 73 20 69 6e |ided han|dlers in|
|00001900| 20 74 68 65 20 4d 43 36 | 38 38 38 31 2f 32 20 6d | the MC6|8881/2 m|
|00001910| 6f 64 65 6c 2c 20 63 6f | 6d 70 61 74 69 62 69 6c |odel, co|mpatibil|
|00001920| 69 74 79 20 69 73 20 61 | 20 70 72 6f 62 6c 65 6d |ity is a| problem|
|00001930| 20 66 6f 72 20 6f 6c 64 | 20 75 73 65 72 20 63 6f | for old| user co|
|00001940| 64 65 20 74 68 61 74 20 | 63 6f 6e 74 61 69 6e 73 |de that |contains|
|00001950| 20 66 6c 6f 61 74 69 6e | 67 2d 70 6f 69 6e 74 20 | floatin|g-point |
|00001960| 65 78 63 65 70 74 69 6f | 6e 20 68 61 6e 64 6c 65 |exceptio|n handle|
|00001970| 72 73 2e 20 4c 61 74 65 | 72 20 73 65 63 74 69 6f |rs. Late|r sectio|
|00001980| 6e 73 20 77 69 6c 6c 20 | 61 64 64 72 65 73 73 20 |ns will |address |
|00001990| 74 68 65 20 69 73 73 75 | 65 73 20 6f 66 20 63 6f |the issu|es of co|
|000019a0| 6d 70 61 74 69 62 69 6c | 69 74 79 20 69 6e 20 6d |mpatibil|ity in m|
|000019b0| 6f 72 65 20 64 65 74 61 | 69 6c 2e 0d 45 6d 75 6c |ore deta|il..Emul|
|000019c0| 61 74 69 6f 6e 20 6f 66 | 20 55 6e 69 6d 70 6c 65 |ation of| Unimple|
|000019d0| 6d 65 6e 74 65 64 20 46 | 50 55 20 49 6e 73 74 72 |mented F|PU Instr|
|000019e0| 75 63 74 69 6f 6e 73 0d | 54 68 65 20 66 6f 6c 6c |uctions.|The foll|
|000019f0| 6f 77 69 6e 67 20 4d 43 | 36 38 38 38 31 2f 32 20 |owing MC|68881/2 |
|00001a00| 61 72 69 74 68 6d 65 74 | 69 63 20 69 6e 73 74 72 |arithmet|ic instr|
|00001a10| 75 63 74 69 6f 6e 73 20 | 61 72 65 20 65 6d 75 6c |uctions |are emul|
|00001a20| 61 74 65 64 20 62 79 20 | 74 68 65 20 46 50 53 50 |ated by |the FPSP|
|00001a30| 2c 20 77 68 69 63 68 20 | 70 72 6f 64 75 63 65 73 |, which |produces|
|00001a40| 20 72 65 73 75 6c 74 73 | 20 61 6e 64 20 65 78 63 | results| and exc|
|00001a50| 65 70 74 69 6f 6e 73 20 | 69 64 65 6e 74 69 63 61 |eptions |identica|
|00001a60| 6c 20 74 6f 20 4d 43 36 | 38 38 38 31 2f 32 20 70 |l to MC6|8881/2 p|
|00001a70| 6c 61 74 66 6f 72 6d 73 | 3a 0d 09 46 47 45 54 45 |latforms|:..FGETE|
|00001a80| 58 50 09 09 45 78 74 72 | 61 63 74 20 62 69 6e 61 |XP..Extr|act bina|
|00001a90| 72 79 20 65 78 70 6f 6e | 65 6e 74 20 6f 66 20 73 |ry expon|ent of s|
|00001aa0| 6f 75 72 63 65 0d 09 46 | 47 45 54 4d 41 4e 09 09 |ource..F|GETMAN..|
|00001ab0| 45 78 74 72 61 63 74 20 | 6d 61 6e 74 69 73 73 61 |Extract |mantissa|
|00001ac0| 20 28 73 69 67 6e 69 66 | 69 63 61 6e 64 29 20 6f | (signif|icand) o|
|00001ad0| 66 20 73 6f 75 72 63 65 | 0d 09 46 49 4e 54 09 09 |f source|..FINT..|
|00001ae0| 09 52 6f 75 6e 64 20 73 | 6f 75 72 63 65 20 74 6f |.Round s|ource to|
|00001af0| 20 69 6e 74 65 67 72 61 | 6c 20 76 61 6c 75 65 2c | integra|l value,|
|00001b00| 20 75 73 69 6e 67 20 72 | 6f 75 6e 64 69 6e 67 20 | using r|ounding |
|00001b10| 6d 6f 64 65 20 69 6e 20 | 74 68 65 20 0d 09 09 09 |mode in |the ....|
|00001b20| 09 46 50 43 52 0d 09 46 | 49 4e 54 52 5a 09 09 52 |.FPCR..F|INTRZ..R|
|00001b30| 6f 75 6e 64 20 73 6f 75 | 72 63 65 20 74 6f 20 69 |ound sou|rce to i|
|00001b40| 6e 74 65 67 72 61 6c 20 | 76 61 6c 75 65 2c 20 75 |ntegral |value, u|
|00001b50| 73 69 6e 67 20 72 6f 75 | 6e 64 2d 74 6f 2d 7a 65 |sing rou|nd-to-ze|
|00001b60| 72 6f 20 6d 6f 64 65 0d | 09 46 4d 4f 44 09 09 09 |ro mode.|.FMOD...|
|00001b70| 4d 6f 64 75 6c 6f 20 72 | 65 6d 61 69 6e 64 65 72 |Modulo r|emainder|
|00001b80| 20 6f 66 20 64 65 73 74 | 69 6e 61 74 69 6f 6e 20 | of dest|ination |
|00001b90| d6 20 73 6f 75 72 63 65 | 20 77 69 74 68 20 73 69 |. source| with si|
|00001ba0| 67 6e 20 61 6e 64 20 6c | 6f 77 65 73 74 20 09 09 |gn and l|owest ..|
|00001bb0| 09 09 73 65 76 65 6e 20 | 62 69 74 73 20 6f 66 20 |..seven |bits of |
|00001bc0| 71 75 6f 74 69 65 6e 74 | 20 64 65 6c 69 76 65 72 |quotient| deliver|
|00001bd0| 65 64 20 69 6e 20 46 50 | 20 73 74 61 74 75 73 20 |ed in FP| status |
|00001be0| 72 65 67 69 73 74 65 72 | 20 28 46 50 53 52 29 20 |register| (FPSR) |
|00001bf0| 0d 09 09 09 09 71 75 6f | 74 69 65 6e 74 20 62 79 |.....quo|tient by|
|00001c00| 74 65 0d 09 46 4d 4f 56 | 45 43 52 09 09 4d 6f 76 |te..FMOV|ECR..Mov|
|00001c10| 65 20 63 6f 6e 73 74 61 | 6e 74 20 52 4f 4d 20 74 |e consta|nt ROM t|
|00001c20| 6f 20 46 50 20 64 61 74 | 61 20 72 65 67 69 73 74 |o FP dat|a regist|
|00001c30| 65 72 0d 09 46 52 45 4d | 09 09 09 49 45 45 45 20 |er..FREM|...IEEE |
|00001c40| 72 65 6d 61 69 6e 64 65 | 72 20 6f 66 20 64 65 73 |remainde|r of des|
|00001c50| 74 69 6e 61 74 69 6f 6e | 20 d6 20 73 6f 75 72 63 |tination| . sourc|
|00001c60| 65 20 77 69 74 68 20 73 | 69 67 6e 20 61 6e 64 20 |e with s|ign and |
|00001c70| 6c 6f 77 65 73 74 20 0d | 09 09 09 09 73 65 76 65 |lowest .|....seve|
|00001c80| 6e 20 62 69 74 73 20 6f | 66 20 71 75 6f 74 69 65 |n bits o|f quotie|
|00001c90| 6e 74 20 64 65 6c 69 76 | 65 72 65 64 20 69 6e 20 |nt deliv|ered in |
|00001ca0| 46 50 53 52 20 71 75 6f | 74 69 65 6e 74 20 62 79 |FPSR quo|tient by|
|00001cb0| 74 65 0d 09 46 53 43 41 | 4c 45 09 09 53 63 61 6c |te..FSCA|LE..Scal|
|00001cc0| 65 20 28 6d 75 6c 74 69 | 70 6c 79 29 20 64 65 73 |e (multi|ply) des|
|00001cd0| 74 69 6e 61 74 69 6f 6e | 20 62 79 20 32 5e 28 28 |tination| by 2^((|
|00001ce0| 69 6e 74 29 20 73 6f 75 | 72 63 65 29 2e 0d 54 68 |int) sou|rce)..Th|
|00001cf0| 65 20 66 6f 6c 6c 6f 77 | 69 6e 67 20 4d 43 36 38 |e follow|ing MC68|
|00001d00| 38 38 31 2f 32 20 74 72 | 61 6e 73 63 65 6e 64 65 |881/2 tr|anscende|
|00001d10| 6e 74 61 6c 20 66 75 6e | 63 74 69 6f 6e 73 20 61 |ntal fun|ctions a|
|00001d20| 72 65 20 65 6d 75 6c 61 | 74 65 64 20 62 79 20 74 |re emula|ted by t|
|00001d30| 68 65 20 46 50 53 50 3a | 0d 09 46 41 43 4f 53 09 |he FPSP:|..FACOS.|
|00001d40| 09 49 6e 76 65 72 73 65 | 20 28 61 72 63 29 20 63 |.Inverse| (arc) c|
|00001d50| 6f 73 69 6e 65 20 28 72 | 61 64 69 61 6e 73 29 0d |osine (r|adians).|
|00001d60| 09 46 41 53 49 4e 09 09 | 49 6e 76 65 72 73 65 20 |.FASIN..|Inverse |
|00001d70| 28 61 72 63 29 20 73 69 | 6e 65 20 28 72 61 64 69 |(arc) si|ne (radi|
|00001d80| 61 6e 73 29 0d 09 46 41 | 54 41 4e 09 09 49 6e 76 |ans)..FA|TAN..Inv|
|00001d90| 65 72 73 65 20 28 61 72 | 63 29 20 74 61 6e 67 65 |erse (ar|c) tange|
|00001da0| 6e 74 20 28 72 61 64 69 | 61 6e 73 29 0d 09 46 41 |nt (radi|ans)..FA|
|00001db0| 54 41 4e 48 09 09 49 6e | 76 65 72 73 65 20 28 61 |TANH..In|verse (a|
|00001dc0| 72 63 29 20 68 79 70 65 | 72 62 6f 6c 69 63 20 74 |rc) hype|rbolic t|
|00001dd0| 61 6e 67 65 6e 74 0d 09 | 46 43 4f 53 09 09 09 43 |angent..|FCOS...C|
|00001de0| 6f 73 69 6e 65 20 6f 66 | 20 73 6f 75 72 63 65 20 |osine of| source |
|00001df0| 69 6e 20 72 61 64 69 61 | 6e 73 0d 09 46 43 4f 53 |in radia|ns..FCOS|
|00001e00| 48 09 09 48 79 70 65 72 | 62 6f 6c 69 63 20 63 6f |H..Hyper|bolic co|
|00001e10| 73 69 6e 65 0d 09 46 45 | 54 4f 58 09 09 42 61 73 |sine..FE|TOX..Bas|
|00001e20| 65 20 65 20 70 6f 77 65 | 72 20 28 65 5e 73 6f 75 |e e powe|r (e^sou|
|00001e30| 72 63 65 29 0d 09 46 45 | 54 4f 58 4d 31 09 09 65 |rce)..FE|TOXM1..e|
|00001e40| 5e 73 6f 75 72 63 65 20 | 2d 20 31 2e 30 0d 09 46 |^source |- 1.0..F|
|00001e50| 4c 4f 47 31 30 09 09 42 | 61 73 65 20 31 30 20 6c |LOG10..B|ase 10 l|
|00001e60| 6f 67 61 72 69 74 68 6d | 0d 09 46 4c 4f 47 32 09 |ogarithm|..FLOG2.|
|00001e70| 09 42 61 73 65 20 32 20 | 6c 6f 67 61 72 69 74 68 |.Base 2 |logarith|
|00001e80| 6d 0d 09 46 4c 4f 47 4e | 09 09 42 61 73 65 20 65 |m..FLOGN|..Base e|
|00001e90| 20 28 6e 61 74 75 72 61 | 6c 29 20 6c 6f 67 61 72 | (natura|l) logar|
|00001ea0| 69 74 68 6d 0d 09 46 4c | 4f 47 4e 50 31 09 09 42 |ithm..FL|OGNP1..B|
|00001eb0| 61 73 65 20 65 20 28 6e | 61 74 75 72 61 6c 29 20 |ase e (n|atural) |
|00001ec0| 6c 6f 67 61 72 69 74 68 | 6d 20 6f 66 20 28 73 6f |logarith|m of (so|
|00001ed0| 75 72 63 65 20 2b 20 31 | 2e 30 29 0d 09 46 53 49 |urce + 1|.0)..FSI|
|00001ee0| 4e 09 09 09 53 69 6e 65 | 20 6f 66 20 73 6f 75 72 |N...Sine| of sour|
|00001ef0| 63 65 20 69 6e 20 72 61 | 64 69 61 6e 73 0d 09 46 |ce in ra|dians..F|
|00001f00| 53 49 4e 43 4f 53 09 09 | 53 69 6d 75 6c 74 61 6e |SINCOS..|Simultan|
|00001f10| 65 6f 75 73 20 73 69 6e | 65 20 61 6e 64 20 63 6f |eous sin|e and co|
|00001f20| 73 69 6e 65 20 28 74 77 | 6f 20 64 65 73 74 69 6e |sine (tw|o destin|
|00001f30| 61 74 69 6f 6e 20 72 65 | 67 69 73 74 65 72 73 29 |ation re|gisters)|
|00001f40| 0d 09 46 53 49 4e 48 09 | 09 48 79 70 65 72 62 6f |..FSINH.|.Hyperbo|
|00001f50| 6c 69 63 20 73 69 6e 65 | 0d 09 46 54 41 4e 09 09 |lic sine|..FTAN..|
|00001f60| 09 54 61 6e 67 65 6e 74 | 20 6f 66 20 73 6f 75 72 |.Tangent| of sour|
|00001f70| 63 65 20 69 6e 20 72 61 | 64 69 61 6e 73 0d 09 46 |ce in ra|dians..F|
|00001f80| 54 41 4e 48 09 09 48 79 | 70 65 72 62 6f 6c 69 63 |TANH..Hy|perbolic|
|00001f90| 20 74 61 6e 67 65 6e 74 | 0d 09 46 54 45 4e 54 4f | tangent|..FTENTO|
|00001fa0| 58 09 09 31 30 2e 30 5e | 73 6f 75 72 63 65 0d 09 |X..10.0^|source..|
|00001fb0| 46 54 57 4f 54 4f 58 09 | 09 32 2e 30 5e 73 6f 75 |FTWOTOX.|.2.0^sou|
|00001fc0| 72 63 65 0d 54 68 65 20 | 61 6c 67 6f 72 69 74 68 |rce.The |algorith|
|00001fd0| 6d 73 20 75 73 65 64 20 | 62 79 20 74 68 65 20 46 |ms used |by the F|
|00001fe0| 50 53 50 20 74 6f 20 63 | 61 6c 63 75 6c 61 74 65 |PSP to c|alculate|
|00001ff0| 20 74 72 61 6e 73 63 65 | 6e 64 65 6e 74 61 6c 20 | transce|ndental |
|00002000| 66 75 6e 63 74 69 6f 6e | 73 20 61 72 65 20 62 6f |function|s are bo|
|00002010| 74 68 20 61 63 63 75 72 | 61 74 65 20 61 6e 64 20 |th accur|ate and |
|00002020| 66 61 73 74 2e 20 52 65 | 73 75 6c 74 73 20 77 69 |fast. Re|sults wi|
|00002030| 6c 6c 20 6e 6f 74 20 61 | 6c 77 61 79 73 20 61 67 |ll not a|lways ag|
|00002040| 72 65 65 20 77 69 74 68 | 20 74 68 6f 73 65 20 6f |ree with| those o|
|00002050| 66 20 74 68 65 20 4d 43 | 36 38 38 38 31 2f 32 2e |f the MC|68881/2.|
|00002060| 20 57 68 65 6e 20 74 68 | 65 79 20 64 69 73 61 67 | When th|ey disag|
|00002070| 72 65 65 2c 20 74 68 65 | 20 46 50 53 50 20 69 73 |ree, the| FPSP is|
|00002080| 20 67 65 6e 65 72 61 6c | 6c 79 20 6d 6f 72 65 20 | general|ly more |
|00002090| 70 72 65 63 69 73 65 2e | 20 54 68 65 20 70 65 72 |precise.| The per|
|000020a0| 66 6f 72 6d 61 6e 63 65 | 20 6f 66 20 74 68 65 20 |formance| of the |
|000020b0| 36 38 30 34 30 20 46 50 | 53 50 20 6f 6e 20 74 72 |68040 FP|SP on tr|
|000020c0| 61 6e 73 63 65 6e 64 65 | 6e 74 61 6c 20 66 75 6e |anscende|ntal fun|
|000020d0| 63 74 69 6f 6e 73 20 69 | 73 20 72 6f 75 67 68 6c |ctions i|s roughl|
|000020e0| 79 20 65 71 75 69 76 61 | 6c 65 6e 74 20 74 6f 20 |y equiva|lent to |
|000020f0| 74 68 61 74 20 6f 66 20 | 61 20 73 69 6d 69 6c 61 |that of |a simila|
|00002100| 72 6c 79 20 63 6c 6f 63 | 6b 65 64 20 4d 43 36 38 |rly cloc|ked MC68|
|00002110| 30 33 30 2f 4d 43 36 38 | 38 38 32 20 63 6f 6d 62 |030/MC68|882 comb|
|00002120| 69 6e 61 74 69 6f 6e 2e | 0d 57 68 65 6e 20 74 68 |ination.|.When th|
|00002130| 65 20 36 38 30 34 30 20 | 69 6e 20 61 20 51 75 61 |e 68040 |in a Qua|
|00002140| 64 72 61 20 61 74 74 65 | 6d 70 74 73 20 74 6f 20 |dra atte|mpts to |
|00002150| 65 78 65 63 75 74 65 20 | 61 6e 79 20 6f 66 20 74 |execute |any of t|
|00002160| 68 65 20 75 6e 69 6d 70 | 6c 65 6d 65 6e 74 65 64 |he unimp|lemented|
|00002170| 20 4d 43 36 38 38 38 31 | 2f 32 20 69 6e 73 74 72 | MC68881|/2 instr|
|00002180| 75 63 74 69 6f 6e 73 2c | 20 69 74 20 74 72 61 70 |uctions,| it trap|
|00002190| 73 2c 20 76 69 61 20 76 | 65 63 74 6f 72 20 6e 75 |s, via v|ector nu|
|000021a0| 6d 62 65 72 20 31 31 2c | 20 74 68 65 20 75 6e 69 |mber 11,| the uni|
|000021b0| 6d 70 6c 65 6d 65 6e 74 | 65 64 20 46 2d 4c 69 6e |mplement|ed F-Lin|
|000021c0| 65 20 6f 70 63 6f 64 65 | 20 65 78 63 65 70 74 69 |e opcode| excepti|
|000021d0| 6f 6e 20 76 65 63 74 6f | 72 20 73 74 6f 72 65 64 |on vecto|r stored|
|000021e0| 20 61 74 20 76 65 63 74 | 6f 72 20 6f 66 66 73 65 | at vect|or offse|
|000021f0| 74 20 28 6c 6f 77 2d 6d | 65 6d 6f 72 79 20 61 64 |t (low-m|emory ad|
|00002200| 64 72 65 73 73 29 20 24 | 30 30 32 43 20 74 6f 20 |dress) $|002C to |
|00002210| 74 68 65 20 46 50 53 50 | 2e 20 54 68 65 20 63 6f |the FPSP|. The co|
|00002220| 72 72 65 73 70 6f 6e 64 | 69 6e 67 20 65 78 63 65 |rrespond|ing exce|
|00002230| 70 74 69 6f 6e 20 68 61 | 6e 64 6c 65 72 20 69 6e |ption ha|ndler in|
|00002240| 20 74 68 65 20 46 50 53 | 50 20 73 61 76 65 73 20 | the FPS|P saves |
|00002250| 74 68 65 20 46 50 55 20 | 73 74 61 74 65 2c 20 64 |the FPU |state, d|
|00002260| 65 63 6f 64 65 73 20 74 | 68 65 20 69 6e 73 74 72 |ecodes t|he instr|
|00002270| 75 63 74 69 6f 6e 2c 20 | 66 65 74 63 68 65 73 20 |uction, |fetches |
|00002280| 74 68 65 20 6f 70 65 72 | 61 6e 64 28 73 29 2c 20 |the oper|and(s), |
|00002290| 65 6d 75 6c 61 74 65 73 | 20 74 68 65 20 75 6e 69 |emulates| the uni|
|000022a0| 6d 70 6c 65 6d 65 6e 74 | 65 64 20 69 6e 73 74 72 |mplement|ed instr|
|000022b0| 75 63 74 69 6f 6e 2c 20 | 61 6e 64 20 72 65 73 74 |uction, |and rest|
|000022c0| 6f 72 65 73 20 74 68 65 | 20 61 70 70 72 6f 70 72 |ores the| appropr|
|000022d0| 69 61 74 65 20 73 74 61 | 74 65 20 74 6f 20 74 68 |iate sta|te to th|
|000022e0| 65 20 46 50 55 2e 20 4f | 70 65 72 61 6e 64 73 20 |e FPU. O|perands |
|000022f0| 69 6e 76 6f 6c 76 69 6e | 67 20 75 6e 73 75 70 70 |involvin|g unsupp|
|00002300| 6f 72 74 65 64 20 64 61 | 74 61 20 74 79 70 65 73 |orted da|ta types|
|00002310| 20 6f 72 20 66 6f 72 6d | 61 74 20 61 72 65 20 70 | or form|at are p|
|00002320| 72 6f 63 65 73 73 65 64 | 20 61 70 70 72 6f 70 72 |rocessed| appropr|
|00002330| 69 61 74 65 6c 79 20 62 | 79 20 74 68 69 73 20 65 |iately b|y this e|
|00002340| 78 63 65 70 74 69 6f 6e | 20 68 61 6e 64 6c 65 72 |xception| handler|
|00002350| 2e 20 54 6f 20 74 68 65 | 20 75 73 65 72 2c 20 74 |. To the| user, t|
|00002360| 68 65 20 65 6d 75 6c 61 | 74 65 64 20 69 6e 73 74 |he emula|ted inst|
|00002370| 72 75 63 74 69 6f 6e 73 | 20 61 70 70 65 61 72 20 |ructions| appear |
|00002380| 61 73 20 61 74 6f 6d 69 | 63 20 6f 70 65 72 61 74 |as atomi|c operat|
|00002390| 69 6f 6e 73 20 74 68 61 | 74 20 70 72 6f 64 75 63 |ions tha|t produc|
|000023a0| 65 20 76 61 6c 69 64 20 | 72 65 73 75 6c 74 73 20 |e valid |results |
|000023b0| 61 6e 64 20 74 68 61 74 | 20 73 69 67 6e 61 6c 20 |and that| signal |
|000023c0| 74 68 65 20 70 72 6f 70 | 65 72 20 66 6c 6f 61 74 |the prop|er float|
|000023d0| 69 6e 67 2d 70 6f 69 6e | 74 20 65 78 63 65 70 74 |ing-poin|t except|
|000023e0| 69 6f 6e 73 2e 20 49 66 | 20 61 6e 20 65 6d 75 6c |ions. If| an emul|
|000023f0| 61 74 65 64 20 69 6e 73 | 74 72 75 63 74 69 6f 6e |ated ins|truction|
|00002400| 20 72 61 69 73 65 73 20 | 61 6e 20 65 6e 61 62 6c | raises |an enabl|
|00002410| 65 64 20 66 6c 6f 61 74 | 69 6e 67 2d 70 6f 69 6e |ed float|ing-poin|
|00002420| 74 20 65 78 63 65 70 74 | 69 6f 6e 2c 20 70 72 6f |t except|ion, pro|
|00002430| 67 72 61 6d 20 66 6c 6f | 77 20 77 69 6c 6c 20 76 |gram flo|w will v|
|00002440| 65 63 74 6f 72 20 74 6f | 20 74 68 65 20 61 70 70 |ector to| the app|
|00002450| 72 6f 70 72 69 61 74 65 | 20 75 73 65 72 20 65 78 |ropriate| user ex|
|00002460| 63 65 70 74 69 6f 6e 20 | 68 61 6e 64 6c 65 72 2e |ception |handler.|
|00002470| 0d 49 66 20 74 68 65 20 | 63 6f 64 65 20 65 78 65 |.If the |code exe|
|00002480| 63 75 74 69 6e 67 20 69 | 6e 20 61 20 51 75 61 64 |cuting i|n a Quad|
|00002490| 72 61 20 63 6f 6e 74 61 | 69 6e 73 20 61 6e 20 46 |ra conta|ins an F|
|000024a0| 2d 4c 69 6e 65 20 6f 70 | 63 6f 64 65 20 74 68 61 |-Line op|code tha|
|000024b0| 74 20 69 73 20 75 6e 64 | 65 66 69 6e 65 64 20 62 |t is und|efined b|
|000024c0| 79 20 74 68 65 20 69 6e | 73 74 72 75 63 74 69 6f |y the in|structio|
|000024d0| 6e 20 73 65 74 73 20 6f | 66 20 62 6f 74 68 20 74 |n sets o|f both t|
|000024e0| 68 65 20 36 38 30 34 30 | 20 61 6e 64 20 4d 43 36 |he 68040| and MC6|
|000024f0| 38 38 38 31 2f 32 2c 20 | 74 72 61 70 70 69 6e 67 |8881/2, |trapping|
|00002500| 20 74 6f 20 74 68 65 20 | 46 50 53 50 20 76 69 61 | to the |FPSP via|
|00002510| 20 76 65 63 74 6f 72 20 | 31 31 20 61 6c 73 6f 20 | vector |11 also |
|00002520| 61 70 70 6c 69 65 73 2e | 20 49 6e 20 74 68 69 73 |applies.| In this|
|00002530| 20 63 61 73 65 2c 20 74 | 68 65 20 68 61 6e 64 6c | case, t|he handl|
|00002540| 65 72 20 72 65 63 6f 67 | 6e 69 7a 65 73 20 74 68 |er recog|nizes th|
|00002550| 61 74 20 6e 6f 20 65 6d | 75 6c 61 74 69 6f 6e 20 |at no em|ulation |
|00002560| 69 73 20 6e 65 63 65 73 | 73 61 72 79 2c 20 61 6e |is neces|sary, an|
|00002570| 64 20 69 74 20 70 61 73 | 73 65 73 20 63 6f 6e 74 |d it pas|ses cont|
|00002580| 72 6f 6c 20 74 6f 20 74 | 68 65 20 73 79 73 74 65 |rol to t|he syste|
|00002590| 6d 20 46 2d 4c 69 6e 65 | 20 65 78 63 65 70 74 69 |m F-Line| excepti|
|000025a0| 6f 6e 20 68 61 6e 64 6c | 65 72 20 76 69 61 20 61 |on handl|er via a|
|000025b0| 20 73 65 63 6f 6e 64 61 | 72 79 20 76 65 63 74 6f | seconda|ry vecto|
|000025c0| 72 20 73 74 6f 72 65 64 | 20 69 6e 20 6c 6f 77 20 |r stored| in low |
|000025d0| 6d 65 6d 6f 72 79 2e 0d | 43 6f 6d 70 61 74 69 62 |memory..|Compatib|
|000025e0| 69 6c 69 74 79 20 4e 6f | 74 65 0d 49 66 20 61 6e |ility No|te.If an|
|000025f0| 20 61 70 70 6c 69 63 61 | 74 69 6f 6e 2c 20 73 75 | applica|tion, su|
|00002600| 63 68 20 61 73 20 61 20 | 64 65 76 65 6c 6f 70 6d |ch as a |developm|
|00002610| 65 6e 74 20 6f 72 20 64 | 65 62 75 67 67 69 6e 67 |ent or d|ebugging|
|00002620| 20 65 6e 76 69 72 6f 6e | 6d 65 6e 74 2c 20 6e 65 | environ|ment, ne|
|00002630| 65 64 73 20 74 6f 20 69 | 6e 73 74 61 6c 6c 20 69 |eds to i|nstall i|
|00002640| 74 73 20 6f 77 6e 20 46 | 2d 4c 69 6e 65 20 65 78 |ts own F|-Line ex|
|00002650| 63 65 70 74 69 6f 6e 20 | 68 61 6e 64 6c 65 72 20 |ception |handler |
|00002660| 6f 6e 20 51 75 61 64 72 | 61 20 70 6c 61 74 66 6f |on Quadr|a platfo|
|00002670| 72 6d 73 2c 20 69 74 20 | 6d 75 73 74 20 6e 6f 74 |rms, it |must not|
|00002680| 20 6f 76 65 72 77 72 69 | 74 65 20 76 65 63 74 6f | overwri|te vecto|
|00002690| 72 20 31 31 20 61 74 20 | 6f 66 66 73 65 74 20 24 |r 11 at |offset $|
|000026a0| 30 30 32 43 2e 20 49 66 | 20 69 74 20 64 6f 65 73 |002C. If| it does|
|000026b0| 2c 20 65 6d 75 6c 61 74 | 69 6f 6e 20 6f 66 20 74 |, emulat|ion of t|
|000026c0| 68 65 20 75 6e 69 6d 70 | 6c 65 6d 65 6e 74 65 64 |he unimp|lemented|
|000026d0| 20 4d 43 36 38 38 38 31 | 2f 32 20 69 6e 73 74 72 | MC68881|/2 instr|
|000026e0| 75 63 74 69 6f 6e 73 20 | 77 69 6c 6c 20 62 65 20 |uctions |will be |
|000026f0| 6c 6f 73 74 20 77 69 74 | 68 20 64 69 73 61 73 74 |lost wit|h disast|
|00002700| 72 6f 75 73 20 65 66 66 | 65 63 74 73 20 74 6f 20 |rous eff|ects to |
|00002710| 74 68 65 20 65 78 65 63 | 75 74 69 6e 67 20 70 72 |the exec|uting pr|
|00002720| 6f 67 72 61 6d 2e 20 49 | 6e 73 74 65 61 64 2c 20 |ogram. I|nstead, |
|00002730| 74 68 65 20 73 65 63 6f | 6e 64 61 72 79 20 46 2d |the seco|ndary F-|
|00002740| 4c 69 6e 65 20 65 78 63 | 65 70 74 69 6f 6e 20 76 |Line exc|eption v|
|00002750| 65 63 74 6f 72 2c 20 6c | 6f 63 61 74 65 64 20 61 |ector, l|ocated a|
|00002760| 74 20 61 64 64 72 65 73 | 73 20 24 31 46 43 38 2c |t addres|s $1FC8,|
|00002770| 20 73 68 6f 75 6c 64 20 | 62 65 20 75 73 65 64 20 | should |be used |
|00002780| 6f 6e 20 51 75 61 64 72 | 61 20 70 6c 61 74 66 6f |on Quadr|a platfo|
|00002790| 72 6d 73 2e 20 41 73 20 | 69 73 20 74 68 65 20 63 |rms. As |is the c|
|000027a0| 61 73 65 20 6f 6e 20 4d | 43 36 38 38 38 31 2f 32 |ase on M|C68881/2|
|000027b0| 20 70 6c 61 74 66 6f 72 | 6d 73 2c 20 74 68 65 20 | platfor|ms, the |
|000027c0| 61 70 70 6c 69 63 61 74 | 69 6f 6e 20 73 68 6f 75 |applicat|ion shou|
|000027d0| 6c 64 20 73 61 76 65 20 | 74 68 65 20 69 6e 68 65 |ld save |the inhe|
|000027e0| 72 69 74 65 64 20 46 2d | 4c 69 6e 65 20 65 78 63 |rited F-|Line exc|
|000027f0| 65 70 74 69 6f 6e 20 76 | 65 63 74 6f 72 20 28 73 |eption v|ector (s|
|00002800| 65 63 6f 6e 64 61 72 79 | 20 76 65 63 74 6f 72 20 |econdary| vector |
|00002810| 69 6e 20 74 68 65 20 63 | 61 73 65 20 6f 66 20 51 |in the c|ase of Q|
|00002820| 75 61 64 72 61 20 70 6c | 61 74 66 6f 72 6d 73 29 |uadra pl|atforms)|
|00002830| 20 61 6e 64 20 72 65 73 | 74 6f 72 65 20 69 74 20 | and res|tore it |
|00002840| 75 70 6f 6e 20 74 65 72 | 6d 69 6e 61 74 69 6f 6e |upon ter|mination|
|00002850| 20 6f 72 20 63 6f 6e 74 | 65 78 74 20 73 77 69 74 | or cont|ext swit|
|00002860| 63 68 2e 0d 55 6e 69 6d | 70 6c 65 6d 65 6e 74 65 |ch..Unim|plemente|
|00002870| 64 20 44 61 74 61 20 54 | 79 70 65 2f 46 6f 72 6d |d Data T|ype/Form|
|00002880| 61 74 20 53 75 70 70 6f | 72 74 20 69 6e 20 74 68 |at Suppo|rt in th|
|00002890| 65 20 46 50 53 50 0d 54 | 68 65 20 46 50 55 20 69 |e FPSP.T|he FPU i|
|000028a0| 6e 20 74 68 65 20 36 38 | 30 34 30 20 64 6f 65 73 |n the 68|040 does|
|000028b0| 20 6e 6f 74 20 73 75 70 | 70 6f 72 74 20 61 6c 6c | not sup|port all|
|000028c0| 20 6f 66 20 74 68 65 20 | 66 6c 6f 61 74 69 6e 67 | of the |floating|
|000028d0| 2d 70 6f 69 6e 74 20 64 | 61 74 61 20 74 79 70 65 |-point d|ata type|
|000028e0| 73 20 61 6e 64 20 66 6f | 72 6d 61 74 73 20 6f 66 |s and fo|rmats of|
|000028f0| 20 74 68 65 20 4d 43 36 | 38 38 38 31 2f 32 2e 20 | the MC6|8881/2. |
|00002900| 54 68 65 20 66 6f 6c 6c | 6f 77 69 6e 67 20 64 61 |The foll|owing da|
|00002910| 74 61 20 74 79 70 65 73 | 20 72 65 71 75 69 72 65 |ta types| require|
|00002920| 20 46 50 53 50 20 73 75 | 70 70 6f 72 74 3a 0d 09 | FPSP su|pport:..|
|00002930| 64 65 6e 6f 72 6d 61 6c | 69 7a 65 64 20 73 69 6e |denormal|ized sin|
|00002940| 67 6c 65 20 28 53 29 2c | 20 64 6f 75 62 6c 65 20 |gle (S),| double |
|00002950| 28 44 29 2c 20 6f 72 20 | 65 78 74 65 6e 64 65 64 |(D), or |extended|
|00002960| 20 28 58 29 20 70 72 65 | 63 69 73 69 6f 6e 20 6f | (X) pre|cision o|
|00002970| 70 65 72 61 6e 64 20 74 | 6f 20 61 6e 20 46 50 55 |perand t|o an FPU|
|00002980| 20 09 69 6e 73 74 72 75 | 63 74 69 6f 6e 3b 20 61 | .instru|ction; a|
|00002990| 6e 64 20 75 6e 6e 6f 72 | 6d 61 6c 69 7a 65 64 20 |nd unnor|malized |
|000029a0| 58 20 6f 70 65 72 61 6e | 64 20 74 6f 20 61 6e 20 |X operan|d to an |
|000029b0| 46 50 55 20 69 6e 73 74 | 72 75 63 74 69 6f 6e 2e |FPU inst|ruction.|
|000029c0| 0d 54 68 65 20 66 6f 6c | 6c 6f 77 69 6e 67 20 64 |.The fol|lowing d|
|000029d0| 61 74 61 20 66 6f 72 6d | 61 74 20 72 65 71 75 69 |ata form|at requi|
|000029e0| 72 65 73 20 46 50 53 50 | 20 73 75 70 70 6f 72 74 |res FPSP| support|
|000029f0| 3a 0d 09 70 61 63 6b 65 | 64 20 64 65 63 69 6d 61 |:..packe|d decima|
|00002a00| 6c 20 72 65 61 6c 20 28 | 50 29 20 66 6f 72 6d 61 |l real (|P) forma|
|00002a10| 74 20 61 73 20 73 6f 75 | 72 63 65 20 6f 72 20 64 |t as sou|rce or d|
|00002a20| 65 73 74 69 6e 61 74 69 | 6f 6e 20 66 6f 72 20 61 |estinati|on for a|
|00002a30| 6e 20 46 50 55 20 69 6e | 73 74 72 75 63 74 69 6f |n FPU in|structio|
|00002a40| 6e 2e 0d 57 68 65 6e 20 | 74 68 65 20 36 38 30 34 |n..When |the 6804|
|00002a50| 30 20 65 6e 63 6f 75 6e | 74 65 72 73 20 61 6e 20 |0 encoun|ters an |
|00002a60| 75 6e 69 6d 70 6c 65 6d | 65 6e 74 65 64 20 64 61 |unimplem|ented da|
|00002a70| 74 61 20 74 79 70 65 20 | 6f 72 20 66 6f 72 6d 61 |ta type |or forma|
|00002a80| 74 20 69 6e 20 74 68 65 | 20 63 6f 75 72 73 65 20 |t in the| course |
|00002a90| 6f 66 20 65 78 65 63 75 | 74 69 6e 67 20 61 20 68 |of execu|ting a h|
|00002aa0| 61 72 64 77 61 72 65 2d | 73 75 70 70 6f 72 74 65 |ardware-|supporte|
|00002ab0| 64 20 46 50 55 20 69 6e | 73 74 72 75 63 74 69 6f |d FPU in|structio|
|00002ac0| 6e 2c 20 69 74 20 74 72 | 61 70 73 2c 20 76 69 61 |n, it tr|aps, via|
|00002ad0| 20 65 78 63 65 70 74 69 | 6f 6e 20 76 65 63 74 6f | excepti|on vecto|
|00002ae0| 72 20 35 35 2c 20 74 68 | 65 20 46 50 20 75 6e 69 |r 55, th|e FP uni|
|00002af0| 6d 70 6c 65 6d 65 6e 74 | 65 64 20 64 61 74 61 20 |mplement|ed data |
|00002b00| 74 79 70 65 20 65 78 63 | 65 70 74 69 6f 6e 20 76 |type exc|eption v|
|00002b10| 65 63 74 6f 72 20 73 74 | 6f 72 65 64 20 61 74 20 |ector st|ored at |
|00002b20| 76 65 63 74 6f 72 20 6f | 66 66 73 65 74 20 28 6c |vector o|ffset (l|
|00002b30| 6f 77 2d 6d 65 6d 6f 72 | 79 20 61 64 64 72 65 73 |ow-memor|y addres|
|00002b40| 73 29 20 24 30 30 44 43 | 20 74 6f 20 74 68 65 20 |s) $00DC| to the |
|00002b50| 46 50 53 50 2e 20 50 72 | 69 6f 72 20 74 6f 20 74 |FPSP. Pr|ior to t|
|00002b60| 68 65 20 72 65 6c 65 61 | 73 65 20 6f 66 20 74 68 |he relea|se of th|
|00002b70| 65 20 36 38 30 34 30 2c | 20 74 68 69 73 20 61 64 |e 68040,| this ad|
|00002b80| 64 72 65 73 73 20 77 61 | 73 20 75 6e 61 73 73 69 |dress wa|s unassi|
|00002b90| 67 6e 65 64 20 62 75 74 | 20 72 65 73 65 72 76 65 |gned but| reserve|
|00002ba0| 64 20 62 79 20 4d 6f 74 | 6f 72 6f 6c 61 2e 20 54 |d by Mot|orola. T|
|00002bb0| 68 65 20 75 6e 69 6d 70 | 6c 65 6d 65 6e 74 65 64 |he unimp|lemented|
|00002bc0| 20 64 61 74 61 20 74 79 | 70 65 20 65 78 63 65 70 | data ty|pe excep|
|00002bd0| 74 69 6f 6e 20 68 61 6e | 64 6c 65 72 20 69 6e 20 |tion han|dler in |
|00002be0| 74 68 65 20 46 50 53 50 | 20 74 61 6b 65 73 20 74 |the FPSP| takes t|
|00002bf0| 68 65 20 61 70 70 72 6f | 70 72 69 61 74 65 20 61 |he appro|priate a|
|00002c00| 63 74 69 6f 6e 20 66 6f | 72 20 74 68 65 20 69 6e |ction fo|r the in|
|00002c10| 73 74 72 75 63 74 69 6f | 6e 20 61 6e 64 20 74 68 |structio|n and th|
|00002c20| 65 20 65 78 63 65 70 74 | 69 6f 6e 61 6c 20 6f 70 |e except|ional op|
|00002c30| 65 72 61 6e 64 20 6f 72 | 20 66 6f 72 6d 61 74 2e |erand or| format.|
|00002c40| 0d 46 6f 72 20 64 65 6e | 6f 72 6d 61 6c 20 53 2c |.For den|ormal S,|
|00002c50| 20 64 65 6e 6f 72 6d 61 | 6c 20 44 2c 20 61 6e 64 | denorma|l D, and|
|00002c60| 20 61 6c 6c 20 50 20 66 | 6f 72 6d 61 74 20 73 6f | all P f|ormat so|
|00002c70| 75 72 63 65 20 6f 70 65 | 72 61 6e 64 73 2c 20 74 |urce ope|rands, t|
|00002c80| 68 65 20 46 50 53 50 20 | 63 6f 6e 76 65 72 74 73 |he FPSP |converts|
|00002c90| 20 74 68 65 20 76 61 6c | 75 65 73 20 74 6f 20 74 | the val|ues to t|
|00002ca0| 68 65 20 6e 6f 72 6d 61 | 6c 69 7a 65 64 20 58 20 |he norma|lized X |
|00002cb0| 65 71 75 69 76 61 6c 65 | 6e 74 73 2c 20 72 65 73 |equivale|nts, res|
|00002cc0| 74 6f 72 65 73 20 46 50 | 55 20 73 74 61 74 65 2c |tores FP|U state,|
|00002cd0| 20 61 6e 64 20 72 65 73 | 74 61 72 74 73 20 74 68 | and res|tarts th|
|00002ce0| 65 20 6f 70 65 72 61 74 | 69 6f 6e 2e 20 49 66 20 |e operat|ion. If |
|00002cf0| 61 20 73 6f 75 72 63 65 | 20 6f 70 65 72 61 6e 64 |a source| operand|
|00002d00| 20 69 73 20 61 6e 20 75 | 6e 6e 6f 72 6d 61 6c 69 | is an u|nnormali|
|00002d10| 7a 65 64 20 58 20 74 68 | 61 74 20 63 61 6e 20 62 |zed X th|at can b|
|00002d20| 65 20 63 6f 6e 76 65 72 | 74 65 64 20 74 6f 20 61 |e conver|ted to a|
|00002d30| 20 6e 6f 72 6d 61 6c 69 | 7a 65 64 20 58 2c 20 74 | normali|zed X, t|
|00002d40| 68 65 20 69 6e 73 74 72 | 75 63 74 69 6f 6e 20 69 |he instr|uction i|
|00002d50| 73 20 61 6c 73 6f 20 63 | 6f 6d 70 6c 65 74 65 64 |s also c|ompleted|
|00002d60| 20 61 73 20 64 65 73 63 | 72 69 62 65 64 2e 20 49 | as desc|ribed. I|
|00002d70| 66 20 74 68 65 20 69 6e | 73 74 72 75 63 74 69 6f |f the in|structio|
|00002d80| 6e 20 69 73 20 61 20 6d | 6f 76 65 20 6f 75 74 20 |n is a m|ove out |
|00002d90| 74 6f 20 50 20 66 6f 72 | 6d 61 74 20 69 6e 20 6d |to P for|mat in m|
|00002da0| 65 6d 6f 72 79 20 28 46 | 4d 4f 56 45 2e 50 20 46 |emory (F|MOVE.P F|
|00002db0| 50 6e 2c 3c 65 61 3e 29 | 2c 20 74 68 65 20 46 50 |Pn,<ea>)|, the FP|
|00002dc0| 53 50 20 65 6d 75 6c 61 | 74 65 73 20 74 68 65 20 |SP emula|tes the |
|00002dd0| 63 6f 6e 76 65 72 73 69 | 6f 6e 20 66 72 6f 6d 20 |conversi|on from |
|00002de0| 74 68 65 20 65 78 74 65 | 6e 64 65 64 20 73 6f 75 |the exte|nded sou|
|00002df0| 72 63 65 20 66 6f 72 6d | 61 74 20 74 6f 20 50 20 |rce form|at to P |
|00002e00| 66 6f 72 6d 61 74 20 61 | 6e 64 20 77 72 69 74 65 |format a|nd write|
|00002e10| 73 20 74 68 65 20 72 65 | 73 75 6c 74 20 74 6f 20 |s the re|sult to |
|00002e20| 74 68 65 20 65 66 66 65 | 63 74 69 76 65 20 61 64 |the effe|ctive ad|
|00002e30| 64 72 65 73 73 2e 0d 46 | 6f 72 20 64 65 6e 6f 72 |dress..F|or denor|
|00002e40| 6d 61 6c 20 58 20 6f 70 | 65 72 61 6e 64 73 20 6f |mal X op|erands o|
|00002e50| 72 20 75 6e 6e 6f 72 6d | 61 6c 69 7a 65 64 20 58 |r unnorm|alized X|
|00002e60| 20 6f 70 65 72 61 6e 64 | 73 20 74 68 61 74 20 72 | operand|s that r|
|00002e70| 65 64 75 63 65 20 74 6f | 20 64 65 6e 6f 72 6d 61 |educe to| denorma|
|00002e80| 6c 20 58 20 76 61 6c 75 | 65 73 2c 20 74 68 65 20 |l X valu|es, the |
|00002e90| 46 50 53 50 20 63 6f 6e | 76 65 72 74 73 20 73 75 |FPSP con|verts su|
|00002ea0| 63 68 20 6f 70 65 72 61 | 6e 64 73 20 74 6f 20 61 |ch opera|nds to a|
|00002eb0| 6e 20 69 6e 74 65 72 6e | 61 6c 20 6e 6f 72 6d 61 |n intern|al norma|
|00002ec0| 6c 69 7a 65 64 20 66 6f | 72 6d 61 74 20 74 68 61 |lized fo|rmat tha|
|00002ed0| 74 20 63 6f 6e 74 61 69 | 6e 73 20 61 6e 20 65 78 |t contai|ns an ex|
|00002ee0| 74 72 61 20 65 78 70 6f | 6e 65 6e 74 20 62 69 74 |tra expo|nent bit|
|00002ef0| 2c 20 72 65 73 74 6f 72 | 65 73 20 73 74 61 74 65 |, restor|es state|
|00002f00| 20 74 6f 20 74 68 65 20 | 46 50 55 2c 20 61 6e 64 | to the |FPU, and|
|00002f10| 20 72 65 73 74 61 72 74 | 73 20 74 68 65 20 6f 70 | restart|s the op|
|00002f20| 65 72 61 74 69 6f 6e 20 | 69 66 20 6e 6f 20 65 78 |eration |if no ex|
|00002f30| 70 6f 6e 65 6e 74 20 77 | 72 61 70 20 63 6f 6e 64 |ponent w|rap cond|
|00002f40| 69 74 69 6f 6e 20 77 69 | 6c 6c 20 6f 63 63 75 72 |ition wi|ll occur|
|00002f50| 20 28 66 6f 72 20 65 78 | 61 6d 70 6c 65 2c 20 64 | (for ex|ample, d|
|00002f60| 69 76 69 73 69 6f 6e 20 | 6f 66 20 61 20 64 65 6e |ivision |of a den|
|00002f70| 6f 72 6d 61 6c 20 76 61 | 6c 75 65 20 62 79 20 61 |ormal va|lue by a|
|00002f80| 6e 6f 74 68 65 72 20 64 | 65 6e 6f 72 6d 61 6c 20 |nother d|enormal |
|00002f90| 76 61 6c 75 65 29 2e 20 | 4f 74 68 65 72 77 69 73 |value). |Otherwis|
|00002fa0| 65 2c 20 74 68 65 20 46 | 50 53 50 20 65 6d 75 6c |e, the F|PSP emul|
|00002fb0| 61 74 65 73 20 74 68 65 | 20 65 6e 74 69 72 65 20 |ates the| entire |
|00002fc0| 69 6e 73 74 72 75 63 74 | 69 6f 6e 2e 0d 44 65 6e |instruct|ion..Den|
|00002fd0| 6f 72 6d 61 6c 69 7a 65 | 64 20 76 61 6c 75 65 73 |ormalize|d values|
|00002fe0| 20 72 65 73 75 6c 74 69 | 6e 67 20 66 72 6f 6d 20 | resulti|ng from |
|00002ff0| 69 6e 73 74 72 75 63 74 | 69 6f 6e 73 20 65 78 65 |instruct|ions exe|
|00003000| 63 75 74 65 64 20 62 79 | 20 74 68 65 20 36 38 30 |cuted by| the 680|
|00003010| 34 30 20 68 61 72 64 77 | 61 72 65 20 64 6f 20 6e |40 hardw|are do n|
|00003020| 6f 74 20 67 65 6e 65 72 | 61 74 65 20 74 68 65 20 |ot gener|ate the |
|00003030| 75 6e 69 6d 70 6c 65 6d | 65 6e 74 65 64 20 64 61 |unimplem|ented da|
|00003040| 74 61 20 74 79 70 65 20 | 65 78 63 65 70 74 69 6f |ta type |exceptio|
|00003050| 6e 2e 20 49 6e 73 74 65 | 61 64 2c 20 61 20 6e 6f |n. Inste|ad, a no|
|00003060| 6e 2d 6d 61 73 6b 61 62 | 6c 65 20 75 6e 64 65 72 |n-maskab|le under|
|00003070| 66 6c 6f 77 20 65 78 63 | 65 70 74 69 6f 6e 20 6f |flow exc|eption o|
|00003080| 63 63 75 72 73 20 77 68 | 69 63 68 20 69 6e 76 6f |ccurs wh|ich invo|
|00003090| 6b 65 73 20 61 20 68 61 | 6e 64 6c 65 72 20 69 6e |kes a ha|ndler in|
|000030a0| 20 74 68 65 20 46 50 53 | 50 2e 20 54 68 69 73 20 | the FPS|P. This |
|000030b0| 68 61 6e 64 6c 65 72 20 | 72 6f 75 6e 64 73 20 74 |handler |rounds t|
|000030c0| 68 65 20 69 6e 74 65 72 | 6e 61 6c 20 72 65 73 75 |he inter|nal resu|
|000030d0| 6c 74 20 61 70 70 72 6f | 70 72 69 61 74 65 6c 79 |lt appro|priately|
|000030e0| 20 61 63 63 6f 72 64 69 | 6e 67 20 74 6f 20 74 68 | accordi|ng to th|
|000030f0| 65 20 73 70 65 63 69 66 | 69 65 64 20 72 6f 75 6e |e specif|ied roun|
|00003100| 64 69 6e 67 20 70 72 65 | 63 69 73 69 6f 6e 20 61 |ding pre|cision a|
|00003110| 6e 64 20 64 69 72 65 63 | 74 69 6f 6e 20 61 6e 64 |nd direc|tion and|
|00003120| 20 64 65 6c 69 76 65 72 | 73 20 74 68 65 20 72 65 | deliver|s the re|
|00003130| 73 75 6c 74 2e 0d 49 6e | 20 74 68 65 20 63 61 73 |sult..In| the cas|
|00003140| 65 20 6f 66 20 69 6e 73 | 74 72 75 63 74 69 6f 6e |e of ins|truction|
|00003150| 73 20 74 68 61 74 20 61 | 72 65 20 65 6d 75 6c 61 |s that a|re emula|
|00003160| 74 65 64 20 62 79 20 74 | 68 65 20 46 50 53 50 2c |ted by t|he FPSP,|
|00003170| 20 74 68 65 20 70 72 6f | 63 65 73 73 69 6e 67 20 | the pro|cessing |
|00003180| 6f 66 20 75 6e 69 6d 70 | 6c 65 6d 65 6e 74 65 64 |of unimp|lemented|
|00003190| 20 64 61 74 61 20 74 79 | 70 65 2f 66 6f 72 6d 61 | data ty|pe/forma|
|000031a0| 74 20 6f 70 65 72 61 6e | 64 73 20 69 73 20 68 61 |t operan|ds is ha|
|000031b0| 6e 64 6c 65 64 20 77 69 | 74 68 69 6e 20 74 68 65 |ndled wi|thin the|
|000031c0| 20 63 6f 6e 66 69 6e 65 | 73 20 6f 66 20 74 68 65 | confine|s of the|
|000031d0| 20 65 6d 75 6c 61 74 69 | 6f 6e 20 70 72 6f 63 65 | emulati|on proce|
|000031e0| 73 73 2e 20 54 68 61 74 | 20 69 73 2c 20 74 68 65 |ss. That| is, the|
|000031f0| 20 36 38 30 34 30 20 74 | 72 61 70 73 20 74 6f 20 | 68040 t|raps to |
|00003200| 74 68 65 20 46 50 53 50 | d5 73 20 75 6e 69 6d 70 |the FPSP|.s unimp|
|00003210| 6c 65 6d 65 6e 74 65 64 | 20 69 6e 73 74 72 75 63 |lemented| instruc|
|00003220| 74 69 6f 6e 20 68 61 6e | 64 6c 65 72 2c 20 77 68 |tion han|dler, wh|
|00003230| 69 63 68 20 69 73 20 63 | 61 70 61 62 6c 65 20 6f |ich is c|apable o|
|00003240| 66 20 72 65 63 6f 67 6e | 69 7a 69 6e 67 20 61 6e |f recogn|izing an|
|00003250| 64 20 64 65 61 6c 69 6e | 67 20 77 69 74 68 20 73 |d dealin|g with s|
|00003260| 75 63 68 20 6f 70 65 72 | 61 6e 64 73 2e 0d 49 6e |uch oper|ands..In|
|00003270| 73 74 72 75 63 74 69 6f | 6e 73 2c 20 77 68 65 74 |structio|ns, whet|
|00003280| 68 65 72 20 65 6d 75 6c | 61 74 65 64 20 6f 72 20 |her emul|ated or |
|00003290| 6e 6f 74 2c 20 74 68 61 | 74 20 75 73 65 20 74 68 |not, tha|t use th|
|000032a0| 65 20 50 20 66 6f 72 6d | 61 74 20 61 73 20 65 69 |e P form|at as ei|
|000032b0| 74 68 65 72 20 73 6f 75 | 72 63 65 20 6f 72 20 64 |ther sou|rce or d|
|000032c0| 65 73 74 69 6e 61 74 69 | 6f 6e 20 68 61 76 65 20 |estinati|on have |
|000032d0| 72 65 6c 61 74 69 76 65 | 6c 79 20 70 6f 6f 72 20 |relative|ly poor |
|000032e0| 70 65 72 66 6f 72 6d 61 | 6e 63 65 20 62 65 63 61 |performa|nce beca|
|000032f0| 75 73 65 20 74 68 65 79 | 20 72 65 71 75 69 72 65 |use they| require|
|00003300| 20 65 6d 75 6c 61 74 69 | 6f 6e 20 6f 66 20 62 69 | emulati|on of bi|
|00003310| 6e 61 72 79 2d 74 6f 2d | 64 65 63 69 6d 61 6c 20 |nary-to-|decimal |
|00003320| 6f 72 20 64 65 63 69 6d | 61 6c 2d 74 6f 2d 62 69 |or decim|al-to-bi|
|00003330| 6e 61 72 79 20 63 6f 6e | 76 65 72 73 69 6f 6e 73 |nary con|versions|
|00003340| 2e 0d 49 64 69 6f 73 79 | 6e 63 72 61 73 69 65 73 |..Idiosy|ncrasies|
|00003350| 0d 42 69 6e 61 72 79 20 | 6f 70 65 72 61 74 69 6f |.Binary |operatio|
|00003360| 6e 73 20 28 73 6f 75 72 | 63 65 20 61 6e 64 20 64 |ns (sour|ce and d|
|00003370| 65 73 74 69 6e 61 74 69 | 6f 6e 20 6f 70 65 72 61 |estinati|on opera|
|00003380| 6e 64 73 20 61 72 65 20 | 62 6f 74 68 20 69 6e 70 |nds are |both inp|
|00003390| 75 74 73 29 20 77 69 74 | 68 20 50 20 66 6f 72 6d |uts) wit|h P form|
|000033a0| 61 74 20 73 6f 75 72 63 | 65 20 6f 70 65 72 61 6e |at sourc|e operan|
|000033b0| 64 73 20 73 68 6f 75 6c | 64 20 61 76 6f 69 64 20 |ds shoul|d avoid |
|000033c0| 75 73 69 6e 67 20 46 50 | 31 20 61 73 20 74 68 65 |using FP|1 as the|
|000033d0| 20 64 65 73 74 69 6e 61 | 74 69 6f 6e 20 6f 70 65 | destina|tion ope|
|000033e0| 72 61 6e 64 20 62 65 63 | 61 75 73 65 20 61 20 62 |rand bec|ause a b|
|000033f0| 75 67 20 69 6e 20 74 68 | 65 20 46 50 53 50 20 63 |ug in th|e FPSP c|
|00003400| 61 75 73 65 73 20 73 70 | 75 72 69 6f 75 73 20 72 |auses sp|urious r|
|00003410| 65 73 75 6c 74 73 20 69 | 6e 20 74 68 69 73 20 63 |esults i|n this c|
|00003420| 61 73 65 2e 20 49 66 20 | 61 6e 20 75 6e 69 6d 70 |ase. If |an unimp|
|00003430| 6c 65 6d 65 6e 74 65 64 | 20 64 61 74 61 20 74 79 |lemented| data ty|
|00003440| 70 65 20 6f 72 20 66 6f | 72 6d 61 74 20 6f 63 63 |pe or fo|rmat occ|
|00003450| 75 72 73 20 61 73 20 69 | 6e 70 75 74 20 74 6f 20 |urs as i|nput to |
|00003460| 61 6e 20 6f 70 65 72 61 | 74 69 6f 6e 2c 20 74 68 |an opera|tion, th|
|00003470| 65 20 65 78 63 65 70 74 | 69 6f 6e 20 69 73 20 70 |e except|ion is p|
|00003480| 6f 73 74 65 64 20 62 79 | 20 74 68 65 20 36 38 30 |osted by| the 680|
|00003490| 34 30 20 77 68 65 6e 20 | 74 68 65 20 6e 65 78 74 |40 when |the next|
|000034a0| 20 46 50 55 20 69 6e 73 | 74 72 75 63 74 69 6f 6e | FPU ins|truction|
|000034b0| 20 69 73 20 61 74 74 65 | 6d 70 74 65 64 2e 20 54 | is atte|mpted. T|
|000034c0| 68 69 73 20 64 65 66 65 | 72 72 65 64 20 65 78 63 |his defe|rred exc|
|000034d0| 65 70 74 69 6f 6e 20 68 | 61 6e 64 6c 69 6e 67 20 |eption h|andling |
|000034e0| 6d 61 79 20 61 70 70 65 | 61 72 20 6e 6f 74 20 74 |may appe|ar not t|
|000034f0| 6f 20 64 65 6c 69 76 65 | 72 20 74 68 65 20 63 6f |o delive|r the co|
|00003500| 72 72 65 63 74 20 72 65 | 73 75 6c 74 20 69 6e 20 |rrect re|sult in |
|00003510| 61 20 64 65 62 75 67 67 | 69 6e 67 20 65 6e 76 69 |a debugg|ing envi|
|00003520| 72 6f 6e 6d 65 6e 74 20 | 74 68 61 74 20 69 6e 73 |ronment |that ins|
|00003530| 74 61 6c 6c 73 20 61 20 | 62 72 65 61 6b 70 6f 69 |talls a |breakpoi|
|00003540| 6e 74 20 70 72 69 6f 72 | 20 74 6f 20 74 68 65 20 |nt prior| to the |
|00003550| 73 65 63 6f 6e 64 20 46 | 50 55 20 69 6e 73 74 72 |second F|PU instr|
|00003560| 75 63 74 69 6f 6e 2e 0d | 46 50 53 50 20 45 78 63 |uction..|FPSP Exc|
|00003570| 65 70 74 69 6f 6e 20 48 | 61 6e 64 6c 65 72 73 20 |eption H|andlers |
|00003580| 0d 43 65 72 74 61 69 6e | 20 66 6c 6f 61 74 69 6e |.Certain| floatin|
|00003590| 67 2d 70 6f 69 6e 74 20 | 65 78 63 65 70 74 69 6f |g-point |exceptio|
|000035a0| 6e 20 63 6f 6e 64 69 74 | 69 6f 6e 73 20 6f 6e 20 |n condit|ions on |
|000035b0| 74 68 65 20 36 38 30 34 | 30 20 72 65 71 75 69 72 |the 6804|0 requir|
|000035c0| 65 20 69 6e 74 65 72 76 | 65 6e 74 69 6f 6e 20 62 |e interv|ention b|
|000035d0| 79 20 74 68 65 20 46 50 | 53 50 20 69 6e 20 6f 72 |y the FP|SP in or|
|000035e0| 64 65 72 20 74 6f 20 66 | 69 78 20 75 70 20 72 65 |der to f|ix up re|
|000035f0| 73 75 6c 74 73 20 6f 72 | 20 6f 74 68 65 72 20 73 |sults or| other s|
|00003600| 74 61 74 65 2e 20 53 6f | 6d 65 20 6f 66 20 74 68 |tate. So|me of th|
|00003610| 65 20 46 50 53 50 20 65 | 78 63 65 70 74 69 6f 6e |e FPSP e|xception|
|00003620| 20 68 61 6e 64 6c 65 72 | 73 20 61 72 65 20 6e 6f | handler|s are no|
|00003630| 6e 2d 6d 61 73 6b 61 62 | 6c 65 20 69 6e 20 74 68 |n-maskab|le in th|
|00003640| 65 20 73 65 6e 73 65 20 | 74 68 61 74 20 74 68 65 |e sense |that the|
|00003650| 79 20 61 72 65 20 65 78 | 65 63 75 74 65 64 20 72 |y are ex|ecuted r|
|00003660| 65 67 61 72 64 6c 65 73 | 73 20 6f 66 20 77 68 65 |egardles|s of whe|
|00003670| 74 68 65 72 20 6f 72 20 | 6e 6f 74 20 74 68 65 20 |ther or |not the |
|00003680| 65 78 63 65 70 74 69 6f | 6e 20 69 73 20 74 72 61 |exceptio|n is tra|
|00003690| 70 2d 65 6e 61 62 6c 65 | 64 20 62 79 20 74 68 65 |p-enable|d by the|
|000036a0| 20 75 73 65 72 2e 20 41 | 6c 6c 20 6f 66 20 74 68 | user. A|ll of th|
|000036b0| 65 20 46 50 53 50 20 66 | 6c 6f 61 74 69 6e 67 2d |e FPSP f|loating-|
|000036c0| 70 6f 69 6e 74 20 65 78 | 63 65 70 74 69 6f 6e 20 |point ex|ception |
|000036d0| 68 61 6e 64 6c 65 72 73 | 2c 20 77 68 65 74 68 65 |handlers|, whethe|
|000036e0| 72 20 6e 6f 6e 2d 6d 61 | 73 6b 61 62 6c 65 20 6f |r non-ma|skable o|
|000036f0| 72 20 6e 6f 74 2c 20 61 | 72 65 20 76 65 63 74 6f |r not, a|re vecto|
|00003700| 72 65 64 20 76 69 61 20 | 20 4d 6f 74 6f 72 6f 6c |red via | Motorol|
|00003710| 61 2d 64 65 73 69 67 6e | 61 74 65 64 20 6c 6f 63 |a-design|ated loc|
|00003720| 61 74 69 6f 6e 73 20 69 | 6e 20 6c 6f 77 2d 6d 65 |ations i|n low-me|
|00003730| 6d 6f 72 79 20 73 75 70 | 65 72 76 69 73 6f 72 20 |mory sup|ervisor |
|00003740| 61 64 64 72 65 73 73 20 | 73 70 61 63 65 2e 20 49 |address |space. I|
|00003750| 66 20 61 20 75 73 65 72 | 2d 65 6e 61 62 6c 65 64 |f a user|-enabled|
|00003760| 20 65 78 63 65 70 74 69 | 6f 6e 20 6f 63 63 75 72 | excepti|on occur|
|00003770| 73 2c 20 74 68 65 20 46 | 50 53 50 20 65 78 63 65 |s, the F|PSP exce|
|00003780| 70 74 69 6f 6e 20 68 61 | 6e 64 6c 65 72 20 69 73 |ption ha|ndler is|
|00003790| 20 65 78 65 63 75 74 65 | 64 20 66 69 72 73 74 20 | execute|d first |
|000037a0| 62 65 66 6f 72 65 20 76 | 65 63 74 6f 72 69 6e 67 |before v|ectoring|
|000037b0| 20 6f 63 63 75 72 73 20 | 74 6f 20 74 68 65 20 75 | occurs |to the u|
|000037c0| 73 65 72 20 68 61 6e 64 | 6c 65 72 20 76 69 61 20 |ser hand|ler via |
|000037d0| 61 20 73 65 63 6f 6e 64 | 61 72 79 20 76 65 63 74 |a second|ary vect|
|000037e0| 6f 72 20 6d 61 69 6e 74 | 61 69 6e 65 64 20 62 79 |or maint|ained by|
|000037f0| 20 74 68 65 20 4d 61 63 | 69 6e 74 6f 73 68 20 51 | the Mac|intosh Q|
|00003800| 75 61 64 72 61 20 73 79 | 73 74 65 6d 2e 20 54 68 |uadra sy|stem. Th|
|00003810| 65 20 75 73 65 72 20 63 | 6f 64 65 20 6d 75 73 74 |e user c|ode must|
|00003820| 20 6e 6f 74 20 6d 6f 64 | 69 66 79 20 74 68 65 20 | not mod|ify the |
|00003830| 70 72 69 6d 61 72 79 20 | 66 6c 6f 61 74 69 6e 67 |primary |floating|
|00003840| 2d 70 6f 69 6e 74 20 65 | 78 63 65 70 74 69 6f 6e |-point e|xception|
|00003850| 20 76 65 63 74 6f 72 73 | 20 74 6f 20 46 50 53 50 | vectors| to FPSP|
|00003860| 20 65 78 63 65 70 74 69 | 6f 6e 20 68 61 6e 64 6c | excepti|on handl|
|00003870| 65 72 73 2e 20 41 20 6c | 61 74 65 72 20 73 65 63 |ers. A l|ater sec|
|00003880| 74 69 6f 6e 20 77 69 6c | 6c 20 64 65 73 63 72 69 |tion wil|l descri|
|00003890| 62 65 20 69 6e 73 74 61 | 6c 6c 61 74 69 6f 6e 20 |be insta|llation |
|000038a0| 6f 66 20 75 73 65 72 20 | 65 78 63 65 70 74 69 6f |of user |exceptio|
|000038b0| 6e 20 68 61 6e 64 6c 65 | 72 73 2e 0d 54 68 65 20 |n handle|rs..The |
|000038c0| 66 6f 6c 6c 6f 77 69 6e | 67 20 69 73 20 61 20 62 |followin|g is a b|
|000038d0| 72 69 65 66 20 64 65 73 | 63 72 69 70 74 69 6f 6e |rief des|cription|
|000038e0| 20 6f 66 20 46 50 53 50 | 20 65 78 63 65 70 74 69 | of FPSP| excepti|
|000038f0| 6f 6e 20 68 61 6e 64 6c | 65 72 73 3a 0d 42 72 61 |on handl|ers:.Bra|
|00003900| 6e 63 68 2f 53 65 74 20 | 6f 6e 20 55 6e 6f 72 64 |nch/Set |on Unord|
|00003910| 65 72 65 64 20 28 42 53 | 55 4e 29 0d 54 68 69 73 |ered (BS|UN).This|
|00003920| 20 6d 61 73 6b 61 62 6c | 65 20 68 61 6e 64 6c 65 | maskabl|e handle|
|00003930| 72 20 69 73 20 69 6e 76 | 6f 6b 65 64 20 6f 6e 6c |r is inv|oked onl|
|00003940| 79 20 69 66 20 74 68 65 | 20 75 73 65 72 20 68 61 |y if the| user ha|
|00003950| 73 20 65 6e 61 62 6c 65 | 64 20 74 68 65 20 42 53 |s enable|d the BS|
|00003960| 55 4e 20 65 78 63 65 70 | 74 69 6f 6e 2e 20 45 6e |UN excep|tion. En|
|00003970| 74 72 79 20 74 6f 20 74 | 68 69 73 20 68 61 6e 64 |try to t|his hand|
|00003980| 6c 65 72 20 69 73 20 76 | 69 61 20 76 65 63 74 6f |ler is v|ia vecto|
|00003990| 72 20 6e 75 6d 62 65 72 | 20 34 38 20 73 74 6f 72 |r number| 48 stor|
|000039a0| 65 64 20 61 74 20 6c 6f | 63 61 74 69 6f 6e 20 24 |ed at lo|cation $|
|000039b0| 30 30 43 30 2e 20 54 68 | 69 73 20 68 61 6e 64 6c |00C0. Th|is handl|
|000039c0| 65 72 20 75 70 64 61 74 | 65 73 20 74 68 65 20 66 |er updat|es the f|
|000039d0| 6c 6f 61 74 69 6e 67 2d | 70 6f 69 6e 74 20 69 6e |loating-|point in|
|000039e0| 73 74 72 75 63 74 69 6f | 6e 20 61 64 64 72 65 73 |structio|n addres|
|000039f0| 73 20 72 65 67 69 73 74 | 65 72 20 28 46 50 49 41 |s regist|er (FPIA|
|00003a00| 52 29 20 74 6f 20 63 6f | 6e 74 61 69 6e 20 74 68 |R) to co|ntain th|
|00003a10| 65 20 61 64 64 72 65 73 | 73 20 6f 66 20 74 68 65 |e addres|s of the|
|00003a20| 20 66 6c 6f 61 74 69 6e | 67 2d 70 6f 69 6e 74 20 | floatin|g-point |
|00003a30| 62 72 61 6e 63 68 2f 73 | 65 74 20 69 6e 73 74 72 |branch/s|et instr|
|00003a40| 75 63 74 69 6f 6e 20 74 | 68 61 74 20 67 65 6e 65 |uction t|hat gene|
|00003a50| 72 61 74 65 64 20 74 68 | 65 20 65 78 63 65 70 74 |rated th|e except|
|00003a60| 69 6f 6e 2e 20 49 74 20 | 74 68 65 6e 20 69 6e 76 |ion. It |then inv|
|00003a70| 6f 6b 65 73 20 74 68 65 | 20 75 73 65 72 d5 73 20 |okes the| user.s |
|00003a80| 68 61 6e 64 6c 65 72 20 | 76 69 61 20 20 61 20 73 |handler |via a s|
|00003a90| 65 63 6f 6e 64 61 72 79 | 20 42 53 55 4e 20 76 65 |econdary| BSUN ve|
|00003aa0| 63 74 6f 72 2e 0d 49 6e | 65 78 61 63 74 20 52 65 |ctor..In|exact Re|
|00003ab0| 73 75 6c 74 20 28 49 4e | 45 58 31 2f 49 4e 45 58 |sult (IN|EX1/INEX|
|00003ac0| 32 29 0d 4e 6f 20 46 50 | 53 50 20 68 61 6e 64 6c |2).No FP|SP handl|
|00003ad0| 65 72 20 69 73 20 72 65 | 71 75 69 72 65 64 2e 20 |er is re|quired. |
|00003ae0| 57 68 65 6e 20 65 6e 61 | 62 6c 65 64 2c 20 49 4e |When ena|bled, IN|
|00003af0| 45 58 31 20 6f 72 20 49 | 4e 45 58 32 20 65 78 63 |EX1 or I|NEX2 exc|
|00003b00| 65 70 74 69 6f 6e 73 20 | 69 6e 76 6f 6b 65 20 74 |eptions |invoke t|
|00003b10| 68 65 20 75 73 65 72 d5 | 73 20 68 61 6e 64 6c 65 |he user.|s handle|
|00003b20| 72 20 76 69 61 20 76 65 | 63 74 6f 72 20 6e 75 6d |r via ve|ctor num|
|00003b30| 62 65 72 20 34 39 20 61 | 74 20 6c 6f 63 61 74 69 |ber 49 a|t locati|
|00003b40| 6f 6e 20 24 30 30 43 34 | 2e 0d 44 69 76 69 64 65 |on $00C4|..Divide|
|00003b50| 20 62 79 20 5a 65 72 6f | 20 28 44 5a 29 0d 4e 6f | by Zero| (DZ).No|
|00003b60| 20 46 50 53 50 20 68 61 | 6e 64 6c 65 72 20 69 73 | FPSP ha|ndler is|
|00003b70| 20 72 65 71 75 69 72 65 | 64 2e 20 57 68 65 6e 20 | require|d. When |
|00003b80| 65 6e 61 62 6c 65 64 2c | 20 74 68 65 20 75 73 65 |enabled,| the use|
|00003b90| 72 d5 73 20 44 5a 20 68 | 61 6e 64 6c 65 72 20 69 |r.s DZ h|andler i|
|00003ba0| 73 20 69 6e 76 6f 6b 65 | 64 20 76 69 61 20 76 65 |s invoke|d via ve|
|00003bb0| 63 74 6f 72 20 6e 75 6d | 62 65 72 20 35 30 20 61 |ctor num|ber 50 a|
|00003bc0| 74 20 6c 6f 63 61 74 69 | 6f 6e 20 24 30 30 43 38 |t locati|on $00C8|
|00003bd0| 2e 20 0d 55 6e 64 65 72 | 66 6c 6f 77 20 28 55 4e |. .Under|flow (UN|
|00003be0| 46 4c 29 0d 54 68 69 73 | 20 6e 6f 6e 2d 6d 61 73 |FL).This| non-mas|
|00003bf0| 6b 61 62 6c 65 20 68 61 | 6e 64 6c 65 72 20 69 73 |kable ha|ndler is|
|00003c00| 20 65 6e 74 65 72 65 64 | 20 76 69 61 20 76 65 63 | entered| via vec|
|00003c10| 74 6f 72 20 6e 75 6d 62 | 65 72 20 35 31 20 61 74 |tor numb|er 51 at|
|00003c20| 20 6c 6f 63 61 74 69 6f | 6e 20 24 30 30 43 43 2e | locatio|n $00CC.|
|00003c30| 20 49 74 20 64 65 74 65 | 72 6d 69 6e 65 73 20 61 | It dete|rmines a|
|00003c40| 6e 64 20 73 74 6f 72 65 | 73 20 74 68 65 20 70 72 |nd store|s the pr|
|00003c50| 6f 70 65 72 6c 79 20 72 | 6f 75 6e 64 65 64 20 75 |operly r|ounded u|
|00003c60| 6e 64 65 72 66 6c 6f 77 | 20 72 65 73 75 6c 74 20 |nderflow| result |
|00003c70| 62 61 73 65 64 20 75 70 | 6f 6e 20 74 68 65 20 76 |based up|on the v|
|00003c80| 61 6c 75 65 20 6f 66 20 | 74 68 65 20 69 6e 74 65 |alue of |the inte|
|00003c90| 72 6d 65 64 69 61 74 65 | 20 72 65 73 75 6c 74 20 |rmediate| result |
|00003ca0| 61 6e 64 20 74 68 65 20 | 72 6f 75 6e 64 69 6e 67 |and the |rounding|
|00003cb0| 20 70 72 65 63 69 73 69 | 6f 6e 2f 64 69 72 65 63 | precisi|on/direc|
|00003cc0| 74 69 6f 6e 20 6d 6f 64 | 65 73 20 73 74 6f 72 65 |tion mod|es store|
|00003cd0| 64 20 69 6e 20 74 68 65 | 20 46 50 43 52 2e 20 49 |d in the| FPCR. I|
|00003ce0| 66 20 75 6e 64 65 72 66 | 6c 6f 77 20 69 73 20 65 |f underf|low is e|
|00003cf0| 6e 61 62 6c 65 64 20 69 | 6e 20 74 68 65 20 46 50 |nabled i|n the FP|
|00003d00| 43 52 2c 20 74 68 65 20 | 75 73 65 72 d5 73 20 68 |CR, the |user.s h|
|00003d10| 61 6e 64 6c 65 72 20 69 | 73 20 69 6e 76 6f 6b 65 |andler i|s invoke|
|00003d20| 64 20 76 69 61 20 61 20 | 73 65 63 6f 6e 64 61 72 |d via a |secondar|
|00003d30| 79 20 55 4e 46 4c 20 76 | 65 63 74 6f 72 2e 0d 4f |y UNFL v|ector..O|
|00003d40| 70 65 72 61 6e 64 20 45 | 72 72 6f 72 20 28 4f 50 |perand E|rror (OP|
|00003d50| 45 52 52 29 0d 54 68 69 | 73 20 6e 6f 6e 2d 6d 61 |ERR).Thi|s non-ma|
|00003d60| 73 6b 61 62 6c 65 20 68 | 61 6e 64 6c 65 72 20 69 |skable h|andler i|
|00003d70| 73 20 65 6e 74 65 72 65 | 64 20 76 69 61 20 76 65 |s entere|d via ve|
|00003d80| 63 74 6f 72 20 6e 75 6d | 62 65 72 20 35 32 20 61 |ctor num|ber 52 a|
|00003d90| 74 20 6c 6f 63 61 74 69 | 6f 6e 20 24 30 30 44 30 |t locati|on $00D0|
|00003da0| 2e 20 49 74 20 70 72 6f | 76 69 64 65 73 20 63 6f |. It pro|vides co|
|00003db0| 6d 70 61 74 69 62 69 6c | 69 74 79 20 6f 66 20 72 |mpatibil|ity of r|
|00003dc0| 65 73 75 6c 74 73 20 77 | 69 74 68 20 74 68 65 20 |esults w|ith the |
|00003dd0| 4d 43 36 38 38 38 31 2f | 32 20 66 6f 72 20 42 2c |MC68881/|2 for B,|
|00003de0| 20 57 2c 20 61 6e 64 20 | 4c 20 64 65 73 74 69 6e | W, and |L destin|
|00003df0| 61 74 69 6f 6e 20 66 6f | 72 6d 61 74 73 20 77 68 |ation fo|rmats wh|
|00003e00| 65 6e 20 74 68 65 20 73 | 6f 75 72 63 65 20 6f 70 |en the s|ource op|
|00003e10| 65 72 61 6e 64 20 69 73 | 20 61 20 4e 61 4e 20 28 |erand is| a NaN (|
|00003e20| 4e 6f 74 2d 61 2d 4e 75 | 6d 62 65 72 29 2c 20 69 |Not-a-Nu|mber), i|
|00003e30| 6e 66 69 6e 69 74 79 2c | 20 6f 72 20 76 61 6c 75 |nfinity,| or valu|
|00003e40| 65 20 74 6f 6f 20 6c 61 | 72 67 65 20 66 6f 72 20 |e too la|rge for |
|00003e50| 74 68 65 20 69 6e 74 65 | 67 65 72 20 66 6f 72 6d |the inte|ger form|
|00003e60| 61 74 2e 20 49 66 20 74 | 68 65 20 4f 50 45 52 52 |at. If t|he OPERR|
|00003e70| 20 65 78 63 65 70 74 69 | 6f 6e 20 69 73 20 75 73 | excepti|on is us|
|00003e80| 65 72 2d 65 6e 61 62 6c | 65 64 2c 20 74 68 65 20 |er-enabl|ed, the |
|00003e90| 46 50 53 50 20 68 61 6e | 64 6c 65 72 20 69 6e 76 |FPSP han|dler inv|
|00003ea0| 6f 6b 65 73 20 74 68 65 | 20 75 73 65 72 d5 73 20 |okes the| user.s |
|00003eb0| 68 61 6e 64 6c 65 72 20 | 76 69 61 20 61 20 73 65 |handler |via a se|
|00003ec0| 63 6f 6e 64 61 72 79 20 | 4f 50 45 52 52 20 76 65 |condary |OPERR ve|
|00003ed0| 63 74 6f 72 2e 0d 4f 76 | 65 72 66 6c 6f 77 20 28 |ctor..Ov|erflow (|
|00003ee0| 4f 56 46 4c 29 0d 54 68 | 69 73 20 6e 6f 6e 2d 6d |OVFL).Th|is non-m|
|00003ef0| 61 73 6b 61 62 6c 65 20 | 68 61 6e 64 6c 65 72 20 |askable |handler |
|00003f00| 69 73 20 65 6e 74 65 72 | 65 64 20 76 69 61 20 76 |is enter|ed via v|
|00003f10| 65 63 74 6f 72 20 6e 75 | 6d 62 65 72 20 35 33 20 |ector nu|mber 53 |
|00003f20| 61 74 20 6c 6f 63 61 74 | 69 6f 6e 20 24 30 30 44 |at locat|ion $00D|
|00003f30| 34 2e 20 49 74 20 64 65 | 74 65 72 6d 69 6e 65 73 |4. It de|termines|
|00003f40| 20 61 6e 64 20 73 74 6f | 72 65 73 20 74 68 65 20 | and sto|res the |
|00003f50| 70 72 6f 70 65 72 6c 79 | 20 72 6f 75 6e 64 65 64 |properly| rounded|
|00003f60| 20 6f 76 65 72 66 6c 6f | 77 20 72 65 73 75 6c 74 | overflo|w result|
|00003f70| 20 62 61 73 65 64 20 6f | 6e 20 74 68 65 20 76 61 | based o|n the va|
|00003f80| 6c 75 65 20 6f 66 20 74 | 68 65 20 69 6e 74 65 72 |lue of t|he inter|
|00003f90| 6d 65 64 69 61 74 65 20 | 72 65 73 75 6c 74 20 61 |mediate |result a|
|00003fa0| 6e 64 20 74 68 65 20 72 | 6f 75 6e 64 69 6e 67 20 |nd the r|ounding |
|00003fb0| 6d 6f 64 65 73 20 73 74 | 6f 72 65 64 20 69 6e 20 |modes st|ored in |
|00003fc0| 74 68 65 20 46 50 43 52 | 2e 20 49 66 20 6f 76 65 |the FPCR|. If ove|
|00003fd0| 72 66 6c 6f 77 20 69 73 | 20 65 6e 61 62 6c 65 64 |rflow is| enabled|
|00003fe0| 20 69 6e 20 74 68 65 20 | 46 50 43 52 2c 20 74 68 | in the |FPCR, th|
|00003ff0| 65 20 75 73 65 72 d5 73 | 20 68 61 6e 64 6c 65 72 |e user.s| handler|
|00004000| 20 69 73 20 69 6e 76 6f | 6b 65 64 20 76 69 61 20 | is invo|ked via |
|00004010| 61 20 73 65 63 6f 6e 64 | 61 72 79 20 4f 56 46 4c |a second|ary OVFL|
|00004020| 20 76 65 63 74 6f 72 2e | 0d 53 69 67 6e 61 6c 69 | vector.|.Signali|
|00004030| 6e 67 20 4e 6f 74 2d 61 | 2d 4e 75 6d 62 65 72 20 |ng Not-a|-Number |
|00004040| 28 53 4e 41 4e 29 0d 54 | 68 69 73 20 6e 6f 6e 2d |(SNAN).T|his non-|
|00004050| 6d 61 73 6b 61 62 6c 65 | 20 68 61 6e 64 6c 65 72 |maskable| handler|
|00004060| 20 69 73 20 65 6e 74 65 | 72 65 64 20 76 69 61 20 | is ente|red via |
|00004070| 76 65 63 74 6f 72 20 6e | 75 6d 62 65 72 20 35 34 |vector n|umber 54|
|00004080| 20 61 74 20 6c 6f 63 61 | 74 69 6f 6e 20 24 30 30 | at loca|tion $00|
|00004090| 44 38 2e 20 49 74 20 70 | 72 6f 76 69 64 65 73 20 |D8. It p|rovides |
|000040a0| 63 6f 6d 70 61 74 69 62 | 69 6c 69 74 79 20 6f 66 |compatib|ility of|
|000040b0| 20 72 65 73 75 6c 74 73 | 20 77 69 74 68 20 74 68 | results| with th|
|000040c0| 65 20 4d 43 36 38 38 38 | 31 2f 32 20 66 6f 72 20 |e MC6888|1/2 for |
|000040d0| 42 2c 20 57 2c 20 61 6e | 64 20 4c 20 64 65 73 74 |B, W, an|d L dest|
|000040e0| 69 6e 61 74 69 6f 6e 20 | 66 6f 72 6d 61 74 73 2e |ination |formats.|
|000040f0| 20 49 66 20 74 68 65 20 | 53 4e 41 4e 20 65 78 63 | If the |SNAN exc|
|00004100| 65 70 74 69 6f 6e 20 69 | 73 20 75 73 65 72 2d 65 |eption i|s user-e|
|00004110| 6e 61 62 6c 65 64 2c 20 | 70 72 6f 67 72 61 6d 20 |nabled, |program |
|00004120| 66 6c 6f 77 20 69 73 20 | 64 69 72 65 63 74 65 64 |flow is |directed|
|00004130| 20 74 6f 20 74 68 65 20 | 75 73 65 72 d5 73 20 68 | to the |user.s h|
|00004140| 61 6e 64 6c 65 72 20 76 | 69 61 20 61 20 73 65 63 |andler v|ia a sec|
|00004150| 6f 6e 64 61 72 79 20 76 | 65 63 74 6f 72 2e 0d 49 |ondary v|ector..I|
|00004160| 66 20 61 20 70 72 6f 67 | 72 61 6d 20 65 6e 61 62 |f a prog|ram enab|
|00004170| 6c 65 73 20 6e 6f 20 66 | 6c 6f 61 74 69 6e 67 2d |les no f|loating-|
|00004180| 70 6f 69 6e 74 20 65 78 | 63 65 70 74 69 6f 6e 73 |point ex|ceptions|
|00004190| 20 69 6e 20 74 68 65 20 | 46 50 43 52 2c 20 63 6f | in the |FPCR, co|
|000041a0| 6d 70 61 74 69 62 69 6c | 69 74 79 20 69 73 20 6e |mpatibil|ity is n|
|000041b0| 6f 74 20 61 6e 20 69 73 | 73 75 65 2e 20 49 6e 20 |ot an is|sue. In |
|000041c0| 74 68 69 73 20 63 61 73 | 65 2c 20 6e 6f 20 75 73 |this cas|e, no us|
|000041d0| 65 72 20 65 78 63 65 70 | 74 69 6f 6e 20 68 61 6e |er excep|tion han|
|000041e0| 64 6c 65 72 73 20 6e 65 | 65 64 20 62 65 20 69 6e |dlers ne|ed be in|
|000041f0| 73 74 61 6c 6c 65 64 2e | 20 54 68 65 20 70 72 6f |stalled.| The pro|
|00004200| 67 72 61 6d 20 74 72 61 | 70 73 20 74 6f 20 6e 6f |gram tra|ps to no|
|00004210| 6e 2d 6d 61 73 6b 61 62 | 6c 65 20 46 50 53 50 20 |n-maskab|le FPSP |
|00004220| 68 61 6e 64 6c 65 72 73 | 20 61 73 20 72 65 71 75 |handlers| as requ|
|00004230| 69 72 65 64 20 66 6f 72 | 20 61 6e 79 20 66 69 78 |ired for| any fix|
|00004240| 2d 75 70 20 6f 66 20 65 | 78 63 65 70 74 69 6f 6e |-up of e|xception|
|00004250| 61 6c 20 72 65 73 75 6c | 74 73 20 6f 72 20 46 50 |al resul|ts or FP|
|00004260| 55 20 73 74 61 74 65 20 | 61 6e 64 20 74 68 65 6e |U state |and then|
|00004270| 20 72 65 73 75 6d 65 73 | 20 65 78 65 63 75 74 69 | resumes| executi|
|00004280| 6f 6e 2e 0d 50 65 72 66 | 6f 72 6d 61 6e 63 65 20 |on..Perf|ormance |
|00004290| 64 65 67 72 61 64 61 74 | 69 6f 6e 20 62 79 20 6e |degradat|ion by n|
|000042a0| 6f 6e 2d 6d 61 73 6b 61 | 62 6c 65 20 46 50 53 50 |on-maska|ble FPSP|
|000042b0| 20 66 6c 6f 61 74 69 6e | 67 2d 70 6f 69 6e 74 20 | floatin|g-point |
|000042c0| 65 78 63 65 70 74 69 6f | 6e 20 68 61 6e 64 6c 69 |exceptio|n handli|
|000042d0| 6e 67 20 69 73 20 6d 69 | 6e 69 6d 61 6c 20 69 6e |ng is mi|nimal in|
|000042e0| 20 6d 6f 73 74 20 63 61 | 73 65 73 20 62 65 63 61 | most ca|ses beca|
|000042f0| 75 73 65 20 73 75 63 68 | 20 69 6e 74 65 72 76 65 |use such| interve|
|00004300| 6e 74 69 6f 6e 20 69 73 | 20 72 61 72 65 6c 79 20 |ntion is| rarely |
|00004310| 6e 65 65 64 65 64 2e 20 | 54 68 65 20 6d 6f 73 74 |needed. |The most|
|00004320| 20 63 6f 6d 6d 6f 6e 20 | 65 78 63 65 70 74 69 6f | common |exceptio|
|00004330| 6e 2c 20 49 4e 45 58 32 | 2c 20 20 72 65 71 75 69 |n, INEX2|, requi|
|00004340| 72 65 73 20 6e 6f 20 46 | 50 53 50 20 73 75 70 70 |res no F|PSP supp|
|00004350| 6f 72 74 2e 20 55 6e 64 | 65 72 66 6c 6f 77 73 20 |ort. Und|erflows |
|00004360| 61 6e 64 20 6f 76 65 72 | 66 6c 6f 77 73 20 61 72 |and over|flows ar|
|00004370| 65 20 69 6e 66 72 65 71 | 75 65 6e 74 20 77 68 65 |e infreq|uent whe|
|00004380| 6e 20 74 68 65 20 64 65 | 66 61 75 6c 74 20 65 78 |n the de|fault ex|
|00004390| 74 65 6e 64 65 64 20 72 | 6f 75 6e 64 69 6e 67 20 |tended r|ounding |
|000043a0| 70 72 65 63 69 73 69 6f | 6e 20 69 73 20 65 6d 70 |precisio|n is emp|
|000043b0| 6c 6f 79 65 64 2e 20 4f | 50 45 52 52 20 6f 63 63 |loyed. O|PERR occ|
|000043c0| 75 72 72 65 6e 63 65 73 | 20 61 72 65 20 61 6c 73 |urrences| are als|
|000043d0| 6f 20 72 61 72 65 2c 20 | 75 6e 6c 65 73 73 20 6d |o rare, |unless m|
|000043e0| 61 6e 79 20 6f 75 74 2d | 6f 66 2d 72 61 6e 67 65 |any out-|of-range|
|000043f0| 20 63 6f 6e 76 65 72 73 | 69 6f 6e 73 20 6f 63 63 | convers|ions occ|
|00004400| 75 72 20 66 72 6f 6d 20 | 66 6c 6f 61 74 69 6e 67 |ur from |floating|
|00004410| 2d 70 6f 69 6e 74 20 74 | 6f 20 69 6e 74 65 67 65 |-point t|o intege|
|00004420| 72 20 66 6f 72 6d 61 74 | 73 2e 0d 55 73 65 72 20 |r format|s..User |
|00004430| 46 6c 6f 61 74 69 6e 67 | 2d 50 6f 69 6e 74 20 45 |Floating|-Point E|
|00004440| 78 63 65 70 74 69 6f 6e | 20 48 61 6e 64 6c 65 72 |xception| Handler|
|00004450| 73 0d 55 73 65 72 73 20 | 77 68 6f 20 72 65 71 75 |s.Users |who requ|
|00004460| 69 72 65 20 66 6c 6f 61 | 74 69 6e 67 2d 70 6f 69 |ire floa|ting-poi|
|00004470| 6e 74 20 65 78 63 65 70 | 74 69 6f 6e 20 68 61 6e |nt excep|tion han|
|00004480| 64 6c 65 72 73 20 69 6e | 20 74 68 65 69 72 20 61 |dlers in| their a|
|00004490| 70 70 6c 69 63 61 74 69 | 6f 6e 73 20 72 75 6e 6e |pplicati|ons runn|
|000044a0| 69 6e 67 20 6f 6e 20 4d | 61 63 69 6e 74 6f 73 68 |ing on M|acintosh|
|000044b0| 20 51 75 61 64 72 61 20 | 70 6c 61 74 66 6f 72 6d | Quadra |platform|
|000044c0| 73 20 6d 75 73 74 20 65 | 78 65 72 63 69 73 65 20 |s must e|xercise |
|000044d0| 73 6f 6d 65 20 63 61 72 | 65 20 69 6e 20 62 6f 74 |some car|e in bot|
|000044e0| 68 20 74 68 65 20 77 72 | 69 74 69 6e 67 20 61 6e |h the wr|iting an|
|000044f0| 64 20 74 68 65 20 69 6e | 73 74 61 6c 6c 61 74 69 |d the in|stallati|
|00004500| 6f 6e 20 6f 66 20 73 75 | 63 68 20 68 61 6e 64 6c |on of su|ch handl|
|00004510| 65 72 73 2e 20 4d 6f 72 | 65 6f 76 65 72 2c 20 69 |ers. Mor|eover, i|
|00004520| 66 20 61 6e 20 61 70 70 | 6c 69 63 61 74 69 6f 6e |f an app|lication|
|00004530| 20 61 6c 73 6f 20 74 61 | 72 67 65 74 73 20 4d 61 | also ta|rgets Ma|
|00004540| 63 69 6e 74 6f 73 68 20 | 63 6f 6d 70 75 74 65 72 |cintosh |computer|
|00004550| 73 20 77 69 74 68 20 4d | 43 36 38 38 38 31 2f 32 |s with M|C68881/2|
|00004560| 20 63 6f 70 72 6f 63 65 | 73 73 6f 72 73 20 61 6e | coproce|ssors an|
|00004570| 64 20 69 6e 74 65 6e 64 | 73 20 74 6f 20 72 65 73 |d intend|s to res|
|00004580| 75 6d 65 20 70 72 6f 63 | 65 73 73 69 6e 67 20 76 |ume proc|essing v|
|00004590| 69 61 20 61 6e 20 52 54 | 45 20 69 6e 20 61 6e 20 |ia an RT|E in an |
|000045a0| 65 78 63 65 70 74 69 6f | 6e 20 68 61 6e 64 6c 65 |exceptio|n handle|
|000045b0| 72 2c 20 69 74 73 20 65 | 78 63 65 70 74 69 6f 6e |r, its e|xception|
|000045c0| 20 68 61 6e 64 6c 65 72 | 73 20 6d 75 73 74 20 71 | handler|s must q|
|000045d0| 75 65 72 79 20 77 68 69 | 63 68 20 6b 69 6e 64 20 |uery whi|ch kind |
|000045e0| 6f 66 20 46 50 55 20 28 | 4d 43 36 38 38 38 31 2f |of FPU (|MC68881/|
|000045f0| 32 20 6f 72 20 36 38 30 | 34 30 29 20 69 73 20 70 |2 or 680|40) is p|
|00004600| 72 65 73 65 6e 74 20 61 | 6e 64 20 74 68 65 6e 20 |resent a|nd then |
|00004610| 65 78 65 63 75 74 65 20 | 68 61 72 64 77 61 72 65 |execute |hardware|
|00004620| 2d 73 70 65 63 69 66 69 | 63 20 63 6f 64 65 20 62 |-specifi|c code b|
|00004630| 61 73 65 64 20 6f 6e 20 | 74 68 65 20 71 75 65 72 |ased on |the quer|
|00004640| 79 20 72 65 73 75 6c 74 | 2e 20 54 68 65 20 72 65 |y result|. The re|
|00004650| 61 64 65 72 20 69 73 20 | 75 72 67 65 64 20 74 6f |ader is |urged to|
|00004660| 20 63 6f 6e 73 75 6c 74 | 20 74 68 65 20 75 73 65 | consult| the use|
|00004670| 72 20 6d 61 6e 75 61 6c | 73 20 66 6f 72 20 74 68 |r manual|s for th|
|00004680| 65 20 36 38 30 34 30 20 | 61 6e 64 20 4d 43 36 38 |e 68040 |and MC68|
|00004690| 38 38 31 2f 32 20 66 6f | 72 20 64 65 74 61 69 6c |881/2 fo|r detail|
|000046a0| 73 20 6e 6f 74 20 63 6f | 76 65 72 65 64 20 62 79 |s not co|vered by|
|000046b0| 20 74 68 69 73 20 4e 6f | 74 65 2e 0d 45 61 63 68 | this No|te..Each|
|000046c0| 20 66 6c 6f 61 74 69 6e | 67 2d 70 6f 69 6e 74 20 | floatin|g-point |
|000046d0| 65 78 63 65 70 74 69 6f | 6e 20 6f 6e 20 74 68 65 |exceptio|n on the|
|000046e0| 20 36 38 30 34 30 20 69 | 73 20 72 65 70 6f 72 74 | 68040 i|s report|
|000046f0| 65 64 20 62 79 20 65 69 | 74 68 65 72 20 74 68 65 |ed by ei|ther the|
|00004700| 20 63 6f 6e 76 65 72 73 | 69 6f 6e 20 75 6e 69 74 | convers|ion unit|
|00004710| 20 28 43 55 29 20 6f 72 | 20 6e 6f 72 6d 61 6c 69 | (CU) or| normali|
|00004720| 7a 61 74 69 6f 6e 20 75 | 6e 69 74 20 28 4e 55 29 |zation u|nit (NU)|
|00004730| 20 70 69 70 65 6c 69 6e | 65 20 73 74 61 67 65 20 | pipelin|e stage |
|00004740| 6f 66 20 74 68 65 20 46 | 50 55 2e 20 45 78 63 65 |of the F|PU. Exce|
|00004750| 70 74 69 6f 6e 73 20 72 | 65 70 6f 72 74 65 64 20 |ptions r|eported |
|00004760| 62 79 20 74 68 65 20 43 | 55 20 61 72 65 20 63 61 |by the C|U are ca|
|00004770| 6c 6c 65 64 20 45 31 20 | 65 78 63 65 70 74 69 6f |lled E1 |exceptio|
|00004780| 6e 73 3b 20 74 68 65 79 | 20 61 72 65 20 64 65 74 |ns; they| are det|
|00004790| 65 63 74 65 64 20 72 65 | 6c 61 74 69 76 65 6c 79 |ected re|latively|
|000047a0| 20 65 61 72 6c 79 20 69 | 6e 20 74 68 65 20 65 78 | early i|n the ex|
|000047b0| 65 63 75 74 69 6f 6e 20 | 6f 66 20 61 6e 20 46 50 |ecution |of an FP|
|000047c0| 55 20 69 6e 73 74 72 75 | 63 74 69 6f 6e 2e 20 45 |U instru|ction. E|
|000047d0| 78 63 65 70 74 69 6f 6e | 73 20 72 65 70 6f 72 74 |xception|s report|
|000047e0| 65 64 20 62 79 20 74 68 | 65 20 4e 55 20 61 72 65 |ed by th|e NU are|
|000047f0| 20 63 61 6c 6c 65 64 20 | 45 33 20 65 78 63 65 70 | called |E3 excep|
|00004800| 74 69 6f 6e 73 3b 20 74 | 68 65 79 20 61 72 65 20 |tions; t|hey are |
|00004810| 64 65 74 65 63 74 65 64 | 20 6c 61 74 65 20 69 6e |detected| late in|
|00004820| 20 74 68 65 20 65 78 65 | 63 75 74 69 6f 6e 20 6f | the exe|cution o|
|00004830| 66 20 46 50 55 20 69 6e | 73 74 72 75 63 74 69 6f |f FPU in|structio|
|00004840| 6e 73 20 61 73 20 74 68 | 65 20 4e 55 20 61 74 74 |ns as th|e NU att|
|00004850| 65 6d 70 74 73 20 74 6f | 20 6e 6f 72 6d 61 6c 69 |empts to| normali|
|00004860| 7a 65 20 61 6e 64 20 72 | 6f 75 6e 64 20 74 68 65 |ze and r|ound the|
|00004870| 20 69 6e 74 65 72 6d 65 | 64 69 61 74 65 20 72 65 | interme|diate re|
|00004880| 73 75 6c 74 20 66 6f 72 | 20 73 74 6f 72 61 67 65 |sult for| storage|
|00004890| 20 69 6e 20 61 20 64 65 | 73 74 69 6e 61 74 69 6f | in a de|stinatio|
|000048a0| 6e 20 46 50 20 72 65 67 | 69 73 74 65 72 2e 20 45 |n FP reg|ister. E|
|000048b0| 31 20 65 78 63 65 70 74 | 69 6f 6e 73 20 69 6e 63 |1 except|ions inc|
|000048c0| 6c 75 64 65 20 61 6c 6c | 20 66 6c 6f 61 74 69 6e |lude all| floatin|
|000048d0| 67 2d 70 6f 69 6e 74 20 | 65 78 63 65 70 74 69 6f |g-point |exceptio|
|000048e0| 6e 20 74 79 70 65 73 2e | 20 54 68 65 20 6f 6e 6c |n types.| The onl|
|000048f0| 79 20 45 33 20 65 78 63 | 65 70 74 69 6f 6e 73 20 |y E3 exc|eptions |
|00004900| 61 72 65 20 4f 56 46 4c | 2c 20 55 4e 46 4c 2c 20 |are OVFL|, UNFL, |
|00004910| 61 6e 64 20 49 4e 45 58 | 32 20 6f 63 63 75 72 72 |and INEX|2 occurr|
|00004920| 69 6e 67 20 6f 6e 20 6f | 70 63 6c 61 73 73 20 30 |ing on o|pclass 0|
|00004930| 20 28 72 65 67 69 73 74 | 65 72 2d 74 6f 2d 72 65 | (regist|er-to-re|
|00004940| 67 69 73 74 65 72 29 20 | 61 6e 64 20 6f 70 63 6c |gister) |and opcl|
|00004950| 61 73 73 20 32 20 28 6d | 65 6d 6f 72 79 2d 74 6f |ass 2 (m|emory-to|
|00004960| 2d 72 65 67 69 73 74 65 | 72 29 20 69 6e 73 74 72 |-registe|r) instr|
|00004970| 75 63 74 69 6f 6e 73 2e | 20 49 66 20 62 6f 74 68 |uctions.| If both|
|00004980| 20 45 33 20 61 6e 64 20 | 45 31 20 65 78 63 65 70 | E3 and |E1 excep|
|00004990| 74 69 6f 6e 73 20 65 78 | 69 73 74 20 61 74 20 74 |tions ex|ist at t|
|000049a0| 68 65 20 73 61 6d 65 20 | 74 69 6d 65 2c 20 74 68 |he same |time, th|
|000049b0| 65 20 45 33 20 65 78 63 | 65 70 74 69 6f 6e 20 73 |e E3 exc|eption s|
|000049c0| 68 6f 75 6c 64 20 62 65 | 20 68 61 6e 64 6c 65 64 |hould be| handled|
|000049d0| 20 66 69 72 73 74 2c 20 | 61 6c 6c 6f 77 69 6e 67 | first, |allowing|
|000049e0| 20 74 68 65 20 36 38 30 | 34 30 20 74 6f 20 73 75 | the 680|40 to su|
|000049f0| 62 73 65 71 75 65 6e 74 | 6c 79 20 74 72 61 70 20 |bsequent|ly trap |
|00004a00| 74 6f 20 68 61 6e 64 6c | 65 20 74 68 65 20 70 65 |to handl|e the pe|
|00004a10| 6e 64 69 6e 67 20 45 31 | 20 65 78 63 65 70 74 69 |nding E1| excepti|
|00004a20| 6f 6e 2e 0d 54 68 65 72 | 65 20 61 72 65 20 74 77 |on..Ther|e are tw|
|00004a30| 6f 20 46 53 41 56 45 20 | 73 74 61 63 6b 20 66 72 |o FSAVE |stack fr|
|00004a40| 61 6d 65 73 20 66 6f 72 | 20 66 6c 6f 61 74 69 6e |ames for| floatin|
|00004a50| 67 2d 70 6f 69 6e 74 20 | 65 78 63 65 70 74 69 6f |g-point |exceptio|
|00004a60| 6e 73 20 6f 6e 20 74 68 | 65 20 36 38 30 34 30 2e |ns on th|e 68040.|
|00004a70| 20 45 31 20 65 78 63 65 | 70 74 69 6f 6e 73 20 70 | E1 exce|ptions p|
|00004a80| 72 6f 64 75 63 65 20 74 | 68 65 20 75 6e 69 6d 70 |roduce t|he unimp|
|00004a90| 6c 65 6d 65 6e 74 65 64 | 20 69 6e 73 74 72 75 63 |lemented| instruc|
|00004aa0| 74 69 6f 6e 20 46 50 55 | 20 73 74 61 74 65 20 66 |tion FPU| state f|
|00004ab0| 72 61 6d 65 2c 20 61 6e | 64 20 45 33 20 65 78 63 |rame, an|d E3 exc|
|00004ac0| 65 70 74 69 6f 6e 73 20 | 70 72 6f 64 75 63 65 20 |eptions |produce |
|00004ad0| 74 68 65 20 62 75 73 79 | 20 46 50 55 20 73 74 61 |the busy| FPU sta|
|00004ae0| 74 65 20 66 72 61 6d 65 | 2e 20 42 6f 74 68 20 6f |te frame|. Both o|
|00004af0| 66 20 74 68 65 73 65 20 | 66 72 61 6d 65 73 20 62 |f these |frames b|
|00004b00| 65 67 69 6e 20 77 69 74 | 68 20 61 20 31 2d 62 79 |egin wit|h a 1-by|
|00004b10| 74 65 20 76 65 72 73 69 | 6f 6e 20 6e 75 6d 62 65 |te versi|on numbe|
|00004b20| 72 20 66 6f 6c 6c 6f 77 | 65 64 20 62 79 20 61 20 |r follow|ed by a |
|00004b30| 31 2d 62 79 74 65 20 66 | 72 61 6d 65 20 6c 65 6e |1-byte f|rame len|
|00004b40| 67 74 68 2e 20 54 68 65 | 20 76 65 72 73 69 6f 6e |gth. The| version|
|00004b50| 20 6e 75 6d 62 65 72 20 | 66 6f 72 20 51 75 61 64 | number |for Quad|
|00004b60| 72 61 20 36 38 30 34 30 | 73 20 69 73 20 24 34 31 |ra 68040|s is $41|
|00004b70| 2e 20 46 6f 72 20 74 68 | 69 73 20 76 65 72 73 69 |. For th|is versi|
|00004b80| 6f 6e 20 6f 66 20 74 68 | 65 20 36 38 30 34 30 2c |on of th|e 68040,|
|00004b90| 20 74 68 65 20 66 72 61 | 6d 65 20 6c 65 6e 67 74 | the fra|me lengt|
|00004ba0| 68 20 66 6f 72 20 45 31 | 20 65 78 63 65 70 74 69 |h for E1| excepti|
|00004bb0| 6f 6e 73 20 69 73 20 24 | 33 30 2c 20 6d 61 6b 69 |ons is $|30, maki|
|00004bc0| 6e 67 20 74 68 65 20 75 | 6e 69 6d 70 6c 65 6d 65 |ng the u|nimpleme|
|00004bd0| 6e 74 65 64 20 69 6e 73 | 74 72 75 63 74 69 6f 6e |nted ins|truction|
|00004be0| 20 46 50 55 20 73 74 61 | 74 65 20 66 72 61 6d 65 | FPU sta|te frame|
|00004bf0| 20 35 32 20 62 79 74 65 | 73 20 69 6e 20 73 69 7a | 52 byte|s in siz|
|00004c00| 65 20 28 63 6f 75 6e 74 | 69 6e 67 20 74 68 65 20 |e (count|ing the |
|00004c10| 34 2d 62 79 74 65 20 68 | 65 61 64 65 72 29 2e 20 |4-byte h|eader). |
|00004c20| 54 68 65 20 62 75 73 79 | 20 66 72 61 6d 65 20 66 |The busy| frame f|
|00004c30| 6f 72 20 45 33 20 65 78 | 63 65 70 74 69 6f 6e 73 |or E3 ex|ceptions|
|00004c40| 20 68 61 73 20 61 20 66 | 72 61 6d 65 20 6c 65 6e | has a f|rame len|
|00004c50| 67 74 68 20 6f 66 20 24 | 36 30 20 61 6e 64 20 74 |gth of $|60 and t|
|00004c60| 6f 74 61 6c 20 73 69 7a | 65 20 6f 66 20 31 30 30 |otal siz|e of 100|
|00004c70| 20 62 79 74 65 73 2e 20 | 0d 42 6f 74 68 20 36 38 | bytes. |.Both 68|
|00004c80| 30 34 30 20 66 6c 6f 61 | 74 69 6e 67 2d 70 6f 69 |040 floa|ting-poi|
|00004c90| 6e 74 20 65 78 63 65 70 | 74 69 6f 6e 20 46 53 41 |nt excep|tion FSA|
|00004ca0| 56 45 20 73 74 61 63 6b | 20 66 72 61 6d 65 73 20 |VE stack| frames |
|00004cb0| 63 6f 6e 74 61 69 6e 20 | 69 6e 66 6f 72 6d 61 74 |contain |informat|
|00004cc0| 69 6f 6e 20 74 68 61 74 | 20 6d 61 79 20 62 65 20 |ion that| may be |
|00004cd0| 6f 66 20 75 73 65 20 74 | 6f 20 74 68 65 20 75 73 |of use t|o the us|
|00004ce0| 65 72 d5 73 20 65 78 63 | 65 70 74 69 6f 6e 20 68 |er.s exc|eption h|
|00004cf0| 61 6e 64 6c 65 72 2e 20 | 54 68 65 72 65 20 61 72 |andler. |There ar|
|00004d00| 65 20 74 77 6f 20 31 32 | 2d 62 79 74 65 20 66 69 |e two 12|-byte fi|
|00004d10| 65 6c 64 73 20 63 6f 6e | 74 61 69 6e 69 6e 67 20 |elds con|taining |
|00004d20| 74 68 65 20 73 6f 75 72 | 63 65 20 61 6e 64 20 64 |the sour|ce and d|
|00004d30| 65 73 74 69 6e 61 74 69 | 6f 6e 20 6f 70 65 72 61 |estinati|on opera|
|00004d40| 6e 64 73 20 69 6e 20 65 | 78 74 65 6e 64 65 64 20 |nds in e|xtended |
|00004d50| 70 72 65 63 69 73 69 6f | 6e 2e 20 54 68 65 72 65 |precisio|n. There|
|00004d60| 20 61 72 65 20 74 77 6f | 20 33 2d 62 69 74 20 74 | are two| 3-bit t|
|00004d70| 61 67 20 66 69 65 6c 64 | 73 20 77 68 69 63 68 20 |ag field|s which |
|00004d80| 63 6c 61 73 73 69 66 79 | 20 74 68 65 20 73 6f 75 |classify| the sou|
|00004d90| 72 63 65 20 61 6e 64 20 | 64 65 73 74 69 6e 61 74 |rce and |destinat|
|00004da0| 69 6f 6e 20 6f 70 65 72 | 61 6e 64 73 20 61 73 20 |ion oper|ands as |
|00004db0| 74 6f 20 77 68 65 74 68 | 65 72 20 74 68 65 79 20 |to wheth|er they |
|00004dc0| 61 72 65 20 6e 6f 72 6d | 61 6c 69 7a 65 64 2c 20 |are norm|alized, |
|00004dd0| 64 65 6e 6f 72 6d 61 6c | 69 7a 65 64 2c 20 7a 65 |denormal|ized, ze|
|00004de0| 72 6f 2c 20 69 6e 66 69 | 6e 69 74 65 2c 20 6f 72 |ro, infi|nite, or|
|00004df0| 20 4e 61 4e 2e 54 68 65 | 72 65 20 61 72 65 20 74 | NaN.The|re are t|
|00004e00| 77 6f 20 62 69 74 73 20 | 28 45 31 20 61 6e 64 20 |wo bits |(E1 and |
|00004e10| 45 33 29 20 77 68 69 63 | 68 2c 20 69 66 20 73 65 |E3) whic|h, if se|
|00004e20| 74 2c 20 69 6e 64 69 63 | 61 74 65 20 77 68 69 63 |t, indic|ate whic|
|00004e30| 68 20 70 69 70 65 6c 69 | 6e 65 20 73 74 61 67 65 |h pipeli|ne stage|
|00004e40| 20 6f 66 20 74 68 65 20 | 46 50 55 20 28 43 55 20 | of the |FPU (CU |
|00004e50| 6f 72 20 4e 55 29 20 64 | 65 74 65 63 74 65 64 20 |or NU) d|etected |
|00004e60| 74 68 65 20 70 65 6e 64 | 69 6e 67 20 65 78 63 65 |the pend|ing exce|
|00004e70| 70 74 69 6f 6e 28 73 29 | 2e 20 42 6f 74 68 20 46 |ption(s)|. Both F|
|00004e80| 53 41 56 45 20 66 72 61 | 6d 65 73 20 65 6e 63 6f |SAVE fra|mes enco|
|00004e90| 64 65 20 74 68 65 20 63 | 6f 6d 6d 61 6e 64 20 77 |de the c|ommand w|
|00004ea0| 6f 72 64 20 6f 66 20 74 | 68 65 20 65 78 63 65 70 |ord of t|he excep|
|00004eb0| 74 69 6f 6e 61 6c 20 66 | 6c 6f 61 74 69 6e 67 2d |tional f|loating-|
|00004ec0| 70 6f 69 6e 74 20 69 6e | 73 74 72 75 63 74 69 6f |point in|structio|
|00004ed0| 6e 2c 20 61 6c 62 65 69 | 74 20 69 6e 20 64 69 66 |n, albei|t in dif|
|00004ee0| 66 65 72 65 6e 74 20 66 | 69 65 6c 64 73 2e 0d 41 |ferent f|ields..A|
|00004ef0| 73 20 61 20 6d 69 6e 69 | 6d 75 6d 2c 20 75 73 65 |s a mini|mum, use|
|00004f00| 72 20 66 6c 6f 61 74 69 | 6e 67 2d 70 6f 69 6e 74 |r floati|ng-point|
|00004f10| 20 65 78 63 65 70 74 69 | 6f 6e 20 68 61 6e 64 6c | excepti|on handl|
|00004f20| 65 72 73 20 6f 6e 20 36 | 38 30 34 30 20 70 6c 61 |ers on 6|8040 pla|
|00004f30| 74 66 6f 72 6d 73 20 6d | 75 73 74 20 69 73 73 75 |tforms m|ust issu|
|00004f40| 65 20 61 6e 20 46 53 41 | 56 45 20 69 6e 73 74 72 |e an FSA|VE instr|
|00004f50| 75 63 74 69 6f 6e 20 61 | 73 20 74 68 65 20 66 69 |uction a|s the fi|
|00004f60| 72 73 74 20 46 50 55 20 | 6f 70 65 72 61 74 69 6f |rst FPU |operatio|
|00004f70| 6e 2c 20 63 6c 65 61 72 | 20 74 68 65 20 65 78 63 |n, clear| the exc|
|00004f80| 65 70 74 69 6f 6e 20 73 | 74 61 74 65 20 6f 66 20 |eption s|tate of |
|00004f90| 74 68 65 20 46 50 55 2c | 20 61 6e 64 20 72 65 73 |the FPU,| and res|
|00004fa0| 75 6d 65 20 70 72 6f 63 | 65 73 73 69 6e 67 20 76 |ume proc|essing v|
|00004fb0| 69 61 20 74 68 65 20 52 | 54 45 20 69 6e 73 74 72 |ia the R|TE instr|
|00004fc0| 75 63 74 69 6f 6e 2e 20 | 46 6f 72 20 45 33 20 65 |uction. |For E3 e|
|00004fd0| 78 63 65 70 74 69 6f 6e | 73 2c 20 74 68 65 20 45 |xception|s, the E|
|00004fe0| 33 20 62 69 74 20 69 6e | 20 74 68 65 20 46 53 41 |3 bit in| the FSA|
|00004ff0| 56 45 20 73 74 61 63 6b | 20 66 72 61 6d 65 20 6d |VE stack| frame m|
|00005000| 75 73 74 20 62 65 20 63 | 6c 65 61 72 65 64 20 61 |ust be c|leared a|
|00005010| 6e 64 20 74 68 65 20 46 | 52 45 53 54 4f 52 45 20 |nd the F|RESTORE |
|00005020| 69 6e 73 74 72 75 63 74 | 69 6f 6e 20 6d 75 73 74 |instruct|ion must|
|00005030| 20 62 65 20 69 73 73 75 | 65 64 20 70 72 69 6f 72 | be issu|ed prior|
|00005040| 20 74 6f 20 74 68 65 20 | 52 54 45 20 69 6e 73 74 | to the |RTE inst|
|00005050| 72 75 63 74 69 6f 6e 2e | 20 46 6f 72 20 45 31 20 |ruction.| For E1 |
|00005060| 65 78 63 65 70 74 69 6f | 6e 73 2c 20 74 68 65 20 |exceptio|ns, the |
|00005070| 6d 69 6e 69 6d 75 6d 20 | 72 65 71 75 69 72 65 6d |minimum |requirem|
|00005080| 65 6e 74 20 69 73 20 74 | 6f 20 74 68 72 6f 77 20 |ent is t|o throw |
|00005090| 61 77 61 79 20 74 68 65 | 20 46 53 41 56 45 20 73 |away the| FSAVE s|
|000050a0| 74 61 63 6b 20 66 72 61 | 6d 65 20 61 6e 64 20 74 |tack fra|me and t|
|000050b0| 6f 20 72 65 73 75 6d 65 | 20 70 72 6f 63 65 73 73 |o resume| process|
|000050c0| 69 6e 67 20 76 69 61 20 | 52 54 45 2e 20 41 6e 6f |ing via |RTE. Ano|
|000050d0| 74 68 65 72 20 6d 65 74 | 68 6f 64 20 6f 66 20 63 |ther met|hod of c|
|000050e0| 6c 65 61 72 69 6e 67 20 | 74 68 65 20 65 78 63 65 |learing |the exce|
|000050f0| 70 74 69 6f 6e 20 73 74 | 61 74 65 20 66 6f 72 20 |ption st|ate for |
|00005100| 45 31 20 65 78 63 65 70 | 74 69 6f 6e 73 20 69 73 |E1 excep|tions is|
|00005110| 20 74 6f 20 63 6c 65 61 | 72 20 74 68 65 20 45 31 | to clea|r the E1|
|00005120| 20 62 69 74 20 69 6e 20 | 74 68 65 20 46 53 41 56 | bit in |the FSAV|
|00005130| 45 20 73 74 61 63 6b 20 | 66 72 61 6d 65 20 61 6e |E stack |frame an|
|00005140| 64 20 69 73 73 75 65 20 | 74 68 65 20 46 52 45 53 |d issue |the FRES|
|00005150| 54 4f 52 45 20 70 72 69 | 6f 72 20 74 6f 20 74 68 |TORE pri|or to th|
|00005160| 65 20 52 54 45 2e 20 54 | 68 65 20 45 31 20 61 6e |e RTE. T|he E1 an|
|00005170| 64 20 45 33 20 62 69 74 | 73 20 61 72 65 20 62 69 |d E3 bit|s are bi|
|00005180| 74 73 20 32 20 61 6e 64 | 20 31 20 28 62 69 74 20 |ts 2 and| 1 (bit |
|00005190| 70 6f 73 69 74 69 6f 6e | 20 30 20 72 65 70 72 65 |position| 0 repre|
|000051a0| 73 65 6e 74 69 6e 67 20 | 74 68 65 20 6c 65 61 73 |senting |the leas|
|000051b0| 74 20 73 69 67 6e 69 66 | 69 63 61 6e 74 20 62 69 |t signif|icant bi|
|000051c0| 74 29 2c 20 72 65 73 70 | 65 63 74 69 76 65 6c 79 |t), resp|ectively|
|000051d0| 2c 20 6f 66 20 74 68 65 | 20 62 79 74 65 20 77 68 |, of the| byte wh|
|000051e0| 69 63 68 20 69 73 20 6c | 6f 63 61 74 65 64 20 32 |ich is l|ocated 2|
|000051f0| 38 20 62 79 74 65 73 20 | 62 65 6c 6f 77 20 74 68 |8 bytes |below th|
|00005200| 65 20 68 69 67 68 2d 61 | 64 64 72 65 73 73 20 65 |e high-a|ddress e|
|00005210| 6e 64 20 6f 66 20 65 69 | 74 68 65 72 20 46 53 41 |nd of ei|ther FSA|
|00005220| 56 45 20 66 72 61 6d 65 | 2e 0d 4d 69 6e 69 6d 75 |VE frame|..Minimu|
|00005230| 6d 20 46 6c 6f 61 74 69 | 6e 67 2d 50 6f 69 6e 74 |m Floati|ng-Point|
|00005240| 20 45 78 63 65 70 74 69 | 6f 6e 20 48 61 6e 64 6c | Excepti|on Handl|
|00005250| 65 72 20 66 6f 72 20 74 | 68 65 20 4d 43 36 38 38 |er for t|he MC688|
|00005260| 38 31 2f 32 20 61 6e 64 | 20 51 75 61 64 72 61 0d |81/2 and| Quadra.|
|00005270| 54 68 65 20 66 6f 6c 6c | 6f 77 69 6e 67 20 63 6f |The foll|owing co|
|00005280| 64 65 20 73 65 71 75 65 | 6e 63 65 20 73 65 72 76 |de seque|nce serv|
|00005290| 65 73 20 61 73 20 61 20 | 6d 69 6e 69 6d 75 6d 20 |es as a |minimum |
|000052a0| 68 61 6e 64 6c 65 72 20 | 66 6f 72 20 61 6c 6c 20 |handler |for all |
|000052b0| 65 6e 61 62 6c 65 64 20 | 66 6c 6f 61 74 69 6e 67 |enabled |floating|
|000052c0| 2d 70 6f 69 6e 74 20 65 | 78 63 65 70 74 69 6f 6e |-point e|xception|
|000052d0| 73 20 65 78 63 65 70 74 | 20 42 53 55 4e 20 6f 6e |s except| BSUN on|
|000052e0| 20 62 6f 74 68 20 77 69 | 74 68 20 4d 43 36 38 38 | both wi|th MC688|
|000052f0| 38 31 2f 32 20 70 6c 61 | 74 66 6f 72 6d 73 20 61 |81/2 pla|tforms a|
|00005300| 6e 64 20 51 75 61 64 72 | 61 20 63 6f 6d 70 75 74 |nd Quadr|a comput|
|00005310| 65 72 73 2e 20 54 68 69 | 73 20 68 61 6e 64 6c 65 |ers. Thi|s handle|
|00005320| 72 20 73 69 6d 70 6c 79 | 20 63 6c 65 61 72 73 20 |r simply| clears |
|00005330| 74 68 65 20 65 78 63 65 | 70 74 69 6f 6e 61 6c 20 |the exce|ptional |
|00005340| 63 6f 6e 64 69 74 69 6f | 6e 20 69 6e 20 74 68 65 |conditio|n in the|
|00005350| 20 46 50 55 20 61 6e 64 | 20 72 65 73 75 6d 65 73 | FPU and| resumes|
|00005360| 20 65 78 65 63 75 74 69 | 6f 6e 20 77 69 74 68 6f | executi|on witho|
|00005370| 75 74 20 61 74 74 65 6d | 70 74 69 6e 67 20 74 6f |ut attem|pting to|
|00005380| 20 6d 6f 64 69 66 79 20 | 61 6e 79 20 6f 74 68 65 | modify |any othe|
|00005390| 72 20 46 50 55 20 73 74 | 61 74 65 2e 20 41 20 6d |r FPU st|ate. A m|
|000053a0| 69 6e 69 6d 61 6c 20 42 | 53 55 4e 20 68 61 6e 64 |inimal B|SUN hand|
|000053b0| 6c 65 72 20 77 6f 75 6c | 64 20 72 65 71 75 69 72 |ler woul|d requir|
|000053c0| 65 20 61 64 64 69 74 69 | 6f 6e 61 6c 20 69 6e 74 |e additi|onal int|
|000053d0| 65 72 76 65 6e 74 69 6f | 6e 20 28 76 69 61 20 6f |erventio|n (via o|
|000053e0| 6e 65 20 6f 66 20 66 6f | 75 72 20 6d 65 74 68 6f |ne of fo|ur metho|
|000053f0| 64 73 20 6f 75 74 6c 69 | 6e 65 64 20 69 6e 20 74 |ds outli|ned in t|
|00005400| 68 65 20 75 73 65 72 20 | 6d 61 6e 75 61 6c 73 20 |he user |manuals |
|00005410| 66 6f 72 20 74 68 65 20 | 36 38 30 34 30 20 61 6e |for the |68040 an|
|00005420| 64 20 74 68 65 20 4d 43 | 36 38 38 38 31 2f 32 29 |d the MC|68881/2)|
|00005430| 20 74 6f 20 70 72 65 76 | 65 6e 74 20 69 6e 66 69 | to prev|ent infi|
|00005440| 6e 69 74 65 20 6c 6f 6f | 70 69 6e 67 20 6f 6e 20 |nite loo|ping on |
|00005450| 74 68 65 20 42 53 55 4e | 20 74 72 61 70 2e 0d 3b |the BSUN| trap..;|
|00005460| 20 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a | *******|********|
|00005470| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00005480| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00005490| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|000054a0| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 0d 3b 20 4d 69 6e 69 |********|*.; Mini|
|000054b0| 6d 75 6d 20 75 73 65 72 | 20 68 61 6e 64 6c 65 72 |mum user| handler|
|000054c0| 20 66 6f 72 20 65 6e 61 | 62 6c 65 64 20 49 4e 45 | for ena|bled INE|
|000054d0| 58 2c 20 44 5a 2c 20 55 | 4e 46 4c 2c 20 4f 50 45 |X, DZ, U|NFL, OPE|
|000054e0| 52 52 2c 20 4f 56 46 4c | 2c 0d 3b 20 6f 72 20 53 |RR, OVFL|,.; or S|
|000054f0| 4e 41 4e 20 66 6c 6f 61 | 74 69 6e 67 2d 70 6f 69 |NAN floa|ting-poi|
|00005500| 6e 74 20 65 78 63 65 70 | 74 69 6f 6e 20 6f 6e 20 |nt excep|tion on |
|00005510| 65 69 74 68 65 72 20 4d | 43 36 38 38 38 31 2f 32 |either M|C68881/2|
|00005520| 20 6f 72 20 0d 3b 20 4d | 61 63 69 6e 74 6f 73 68 | or .; M|acintosh|
|00005530| 20 51 75 61 64 72 61 20 | 70 6c 61 74 66 6f 72 6d | Quadra |platform|
|00005540| 73 2e 20 0d 3b 0d 3b 20 | 4e 4f 54 45 3a 20 20 46 |s. .;.; |NOTE: F|
|00005550| 6f 72 20 65 6e 61 62 6c | 65 64 20 44 5a 2c 20 4f |or enabl|ed DZ, O|
|00005560| 50 45 52 52 2c 20 61 6e | 64 20 53 4e 41 4e 20 65 |PERR, an|d SNAN e|
|00005570| 78 63 65 70 74 69 6f 6e | 73 20 66 6f 72 20 69 6e |xception|s for in|
|00005580| 73 74 72 75 63 74 69 6f | 6e 73 0d 3b 20 20 20 20 |structio|ns.; |
|00005590| 20 20 20 20 77 69 74 68 | 20 46 50 20 72 65 67 69 | with| FP regi|
|000055a0| 73 74 65 72 20 64 65 73 | 74 69 6e 61 74 69 6f 6e |ster des|tination|
|000055b0| 73 2c 20 6e 6f 20 72 65 | 73 75 6c 74 20 69 73 20 |s, no re|sult is |
|000055c0| 64 65 6c 69 76 65 72 65 | 64 20 61 74 20 61 6c 6c |delivere|d at all|
|000055d0| 20 74 6f 20 74 68 65 0d | 3b 20 20 20 20 20 20 20 | to the.|; |
|000055e0| 20 64 65 73 74 69 6e 61 | 74 69 6f 6e 20 72 65 67 | destina|tion reg|
|000055f0| 69 73 74 65 72 2e 0d 3b | 20 2a 2a 2a 2a 2a 2a 2a |ister..;| *******|
|00005600| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00005610| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00005620| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00005630| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00005640| 2a 0d 48 41 4e 44 4c 45 | 52 3a 0d 09 09 46 53 41 |*.HANDLE|R:...FSA|
|00005650| 56 45 09 09 2d 28 53 50 | 29 09 09 3b 20 73 61 76 |VE..-(SP|)..; sav|
|00005660| 65 20 69 6e 74 65 72 6e | 61 6c 20 46 50 55 20 73 |e intern|al FPU s|
|00005670| 74 61 74 65 0d 09 09 4d | 4f 56 45 2e 4c 09 09 44 |tate...M|OVE.L..D|
|00005680| 30 2c 2d 28 53 50 29 09 | 3b 20 73 61 76 65 20 44 |0,-(SP).|; save D|
|00005690| 30 2c 20 53 54 41 43 4b | 3a 20 20 44 30 20 73 61 |0, STACK|: D0 sa|
|000056a0| 76 65 20 3c 20 46 53 41 | 56 45 20 66 72 61 6d 65 |ve < FSA|VE frame|
|000056b0| 0d 09 09 4d 4f 56 45 51 | 09 09 23 30 2c 44 30 09 |...MOVEQ|..#0,D0.|
|000056c0| 09 3b 20 7a 65 72 6f 20 | 44 30 0d 09 09 4d 4f 56 |.; zero |D0...MOV|
|000056d0| 45 2e 42 09 09 34 28 53 | 50 29 2c 44 30 09 3b 20 |E.B..4(S|P),D0.; |
|000056e0| 4e 55 4c 4c 20 66 72 61 | 6d 65 3f 0d 09 09 42 45 |NULL fra|me?...BE|
|000056f0| 51 2e 42 09 09 40 4e 55 | 4c 4c 09 09 3b 20 79 65 |Q.B..@NU|LL..; ye|
|00005700| 73 2c 20 72 65 73 74 6f | 72 65 20 44 30 20 61 6e |s, resto|re D0 an|
|00005710| 64 20 46 50 55 20 73 74 | 61 74 65 0d 09 09 43 4d |d FPU st|ate...CM|
|00005720| 50 49 2e 42 09 09 23 24 | 34 31 2c 44 30 09 3b 20 |PI.B..#$|41,D0.; |
|00005730| 51 75 61 64 72 61 20 28 | 36 38 30 34 30 29 20 49 |Quadra (|68040) I|
|00005740| 44 3f 0d 09 09 42 4e 45 | 2e 42 09 09 40 43 4f 50 |D?...BNE|.B..@COP|
|00005750| 52 4f 43 09 3b 20 6e 6f | 2c 20 61 73 73 75 6d 65 |ROC.; no|, assume|
|00005760| 20 4d 43 36 38 38 38 31 | 2f 32 0d 3b 20 51 75 61 | MC68881|/2.; Qua|
|00005770| 64 72 61 20 46 53 41 56 | 45 20 66 72 61 6d 65 0d |dra FSAV|E frame.|
|00005780| 09 09 4d 4f 56 45 2e 42 | 09 09 35 28 53 50 29 2c |..MOVE.B|..5(SP),|
|00005790| 44 30 09 3b 20 44 30 20 | 3c 2d 20 66 72 61 6d 65 |D0.; D0 |<- frame|
|000057a0| 20 73 69 7a 65 0d 09 09 | 42 45 51 2e 42 09 09 40 | size...|BEQ.B..@|
|000057b0| 4e 55 4c 4c 09 09 3b 20 | 72 65 73 74 6f 72 65 20 |NULL..; |restore |
|000057c0| 73 74 61 74 65 20 69 66 | 20 36 38 30 34 30 20 49 |state if| 68040 I|
|000057d0| 44 4c 45 20 66 72 61 6d | 65 0d 3b 20 51 75 61 64 |DLE fram|e.; Quad|
|000057e0| 72 61 20 55 4e 49 4d 50 | 4c 45 4d 45 4e 54 45 44 |ra UNIMP|LEMENTED|
|000057f0| 20 49 4e 53 54 52 55 43 | 54 49 4f 4e 20 6f 72 20 | INSTRUC|TION or |
|00005800| 42 55 53 59 20 46 53 41 | 56 45 20 66 72 61 6d 65 |BUSY FSA|VE frame|
|00005810| 0d 09 09 53 55 42 49 2e | 42 09 09 23 32 30 2c 44 |...SUBI.|B..#20,D|
|00005820| 30 09 09 3b 20 44 30 20 | 3c 2d 20 6f 66 66 73 65 |0..; D0 |<- offse|
|00005830| 74 20 6f 66 20 45 31 2f | 45 33 20 62 79 74 65 20 |t of E1/|E3 byte |
|00005840| 66 72 6f 6d 20 28 53 50 | 29 0d 09 09 42 43 4c 52 |from (SP|)...BCLR|
|00005850| 2e 42 09 09 23 31 2c 28 | 53 50 2c 44 30 29 09 3b |.B..#1,(|SP,D0).;|
|00005860| 20 74 65 73 74 20 61 6e | 64 20 63 6c 65 61 72 20 | test an|d clear |
|00005870| 45 33 20 62 79 74 65 0d | 09 09 42 4e 45 2e 42 09 |E3 byte.|..BNE.B.|
|00005880| 09 40 4e 55 4c 4c 09 09 | 3b 20 72 65 73 74 6f 72 |.@NULL..|; restor|
|00005890| 65 20 73 74 61 74 65 20 | 69 66 20 45 33 20 77 61 |e state |if E3 wa|
|000058a0| 73 20 73 65 74 0d 09 09 | 42 43 4c 52 2e 42 09 09 |s set...|BCLR.B..|
|000058b0| 23 32 2c 28 53 50 2c 44 | 30 29 09 3b 20 45 31 20 |#2,(SP,D|0).; E1 |
|000058c0| 65 78 63 65 70 74 69 6f | 6e 2c 20 63 6c 65 61 72 |exceptio|n, clear|
|000058d0| 20 45 31 20 62 79 74 65 | 0d 3b 20 52 65 73 74 6f | E1 byte|.; Resto|
|000058e0| 72 65 20 73 74 61 74 65 | 20 61 6e 64 20 72 65 73 |re state| and res|
|000058f0| 75 6d 65 20 65 78 65 63 | 75 74 69 6f 6e 0d 40 4e |ume exec|ution.@N|
|00005900| 55 4c 4c 3a 09 4d 4f 56 | 45 2e 4c 09 09 28 53 50 |ULL:.MOV|E.L..(SP|
|00005910| 29 2b 2c 44 30 09 3b 20 | 72 65 73 74 6f 72 65 20 |)+,D0.; |restore |
|00005920| 44 30 2c 20 53 54 41 43 | 4b 3a 20 20 46 53 41 56 |D0, STAC|K: FSAV|
|00005930| 45 20 66 72 61 6d 65 0d | 09 09 46 52 45 53 54 4f |E frame.|..FRESTO|
|00005940| 52 45 09 28 53 50 29 2b | 09 09 3b 20 72 65 73 74 |RE.(SP)+|..; rest|
|00005950| 6f 72 65 20 46 50 55 20 | 73 74 61 74 65 0d 09 09 |ore FPU |state...|
|00005960| 52 54 45 09 09 09 09 3b | 20 72 65 73 75 6d 65 20 |RTE....;| resume |
|00005970| 70 72 6f 63 65 73 73 69 | 6e 67 0d 3b 20 4d 43 36 |processi|ng.; MC6|
|00005980| 38 38 38 31 2f 32 20 49 | 44 4c 45 20 46 53 41 56 |8881/2 I|DLE FSAV|
|00005990| 45 20 66 72 61 6d 65 0d | 40 43 4f 50 52 4f 43 3a |E frame.|@COPROC:|
|000059a0| 09 4d 4f 56 45 2e 42 09 | 09 35 28 53 50 29 2c 44 |.MOVE.B.|.5(SP),D|
|000059b0| 30 09 3b 20 44 30 20 3c | 2d 20 49 44 4c 45 20 66 |0.; D0 <|- IDLE f|
|000059c0| 72 61 6d 65 20 73 69 7a | 65 0d 09 09 41 44 44 51 |rame siz|e...ADDQ|
|000059d0| 2e 42 09 09 23 34 2c 44 | 30 09 09 3b 20 63 6f 6d |.B..#4,D|0..; com|
|000059e0| 70 65 6e 73 61 74 65 20 | 66 6f 72 20 44 30 20 73 |pensate |for D0 s|
|000059f0| 61 76 65 20 76 61 6c 75 | 65 20 6f 6e 20 73 74 61 |ave valu|e on sta|
|00005a00| 63 6b 0d 09 09 42 53 45 | 54 2e 42 09 09 23 33 2c |ck...BSE|T.B..#3,|
|00005a10| 28 53 50 2c 44 30 29 09 | 3b 20 73 65 74 20 62 69 |(SP,D0).|; set bi|
|00005a20| 74 20 32 37 20 6f 66 20 | 42 49 55 0d 09 09 42 52 |t 27 of |BIU...BR|
|00005a30| 41 2e 42 09 09 40 4e 55 | 4c 4c 09 09 3b 20 72 65 |A.B..@NU|LL..; re|
|00005a40| 73 74 6f 72 65 20 73 74 | 61 74 65 0d 49 6e 73 74 |store st|ate.Inst|
|00005a50| 61 6c 6c 61 74 69 6f 6e | 20 6f 66 20 55 73 65 72 |allation| of User|
|00005a60| 20 46 6c 6f 61 74 69 6e | 67 2d 50 6f 69 6e 74 20 | Floatin|g-Point |
|00005a70| 45 78 63 65 70 74 69 6f | 6e 20 48 61 6e 64 6c 65 |Exceptio|n Handle|
|00005a80| 72 73 0d 43 75 72 72 65 | 6e 74 20 4d 50 57 20 6c |rs.Curre|nt MPW l|
|00005a90| 61 6e 67 75 61 67 65 20 | 6c 69 62 72 61 72 69 65 |anguage |librarie|
|00005aa0| 73 20 28 4d 50 57 20 32 | 2e 30 2e 32 20 6f 72 20 |s (MPW 2|.0.2 or |
|00005ab0| 6c 61 74 65 72 20 72 65 | 6c 65 61 73 65 73 20 61 |later re|leases a|
|00005ac0| 6e 64 20 4c 61 6e 67 75 | 61 67 65 20 53 79 73 74 |nd Langu|age Syst|
|00005ad0| 65 6d 73 20 46 4f 52 54 | 52 41 4e 20 76 65 72 73 |ems FORT|RAN vers|
|00005ae0| 69 6f 6e 20 33 2e 30 29 | 20 70 72 6f 76 69 64 65 |ion 3.0)| provide|
|00005af0| 20 66 6f 72 20 74 68 65 | 20 76 65 63 74 6f 72 69 | for the| vectori|
|00005b00| 6e 67 20 6f 66 20 75 73 | 65 72 20 66 6c 6f 61 74 |ng of us|er float|
|00005b10| 69 6e 67 2d 70 6f 69 6e | 74 20 65 78 63 65 70 74 |ing-poin|t except|
|00005b20| 69 6f 6e 20 68 61 6e 64 | 6c 65 72 73 20 69 6e 20 |ion hand|lers in |
|00005b30| 61 20 63 6f 6e 73 69 73 | 74 65 6e 74 20 61 6e 64 |a consis|tent and|
|00005b40| 20 70 6f 72 74 61 62 6c | 65 20 66 61 73 68 69 6f | portabl|e fashio|
|00005b50| 6e 20 66 6f 72 20 62 6f | 74 68 20 51 75 61 64 72 |n for bo|th Quadr|
|00005b60| 61 20 61 6e 64 20 4d 43 | 36 38 38 38 31 2f 32 20 |a and MC|68881/2 |
|00005b70| 4d 61 63 69 6e 74 6f 73 | 68 20 70 6c 61 74 66 6f |Macintos|h platfo|
|00005b80| 72 6d 73 2e 20 54 68 65 | 20 43 20 66 75 6e 63 74 |rms. The| C funct|
|00005b90| 69 6f 6e 73 20 73 65 74 | 74 72 61 70 76 65 63 74 |ions set|trapvect|
|00005ba0| 6f 72 20 61 6e 64 20 67 | 65 74 74 72 61 70 76 65 |or and g|ettrapve|
|00005bb0| 63 74 6f 72 2c 20 74 68 | 65 20 50 61 73 63 61 6c |ctor, th|e Pascal|
|00005bc0| 20 70 72 6f 63 65 64 75 | 72 65 73 20 53 65 74 54 | procedu|res SetT|
|00005bd0| 72 61 70 56 65 63 74 6f | 72 20 61 6e 64 20 47 65 |rapVecto|r and Ge|
|00005be0| 74 54 72 61 70 56 65 63 | 74 6f 72 2c 20 61 6e 64 |tTrapVec|tor, and|
|00005bf0| 20 74 68 65 20 4c 61 6e | 67 75 61 67 65 20 53 79 | the Lan|guage Sy|
|00005c00| 73 74 65 6d 73 20 46 4f | 52 54 52 41 4e 20 73 75 |stems FO|RTRAN su|
|00005c10| 62 72 6f 75 74 69 6e 65 | 73 20 53 65 74 54 72 61 |broutine|s SetTra|
|00005c20| 70 56 65 63 74 6f 72 20 | 61 6e 64 20 47 65 74 54 |pVector |and GetT|
|00005c30| 72 61 70 56 65 63 74 6f | 72 20 61 6c 6c 6f 77 20 |rapVecto|r allow |
|00005c40| 75 73 65 72 73 20 74 6f | 20 69 6e 73 74 61 6c 6c |users to| install|
|00005c50| 20 61 6e 64 20 72 65 61 | 64 20 76 65 63 74 6f 72 | and rea|d vector|
|00005c60| 73 20 74 6f 20 74 68 65 | 69 72 20 66 6c 6f 61 74 |s to the|ir float|
|00005c70| 69 6e 67 2d 70 6f 69 6e | 74 20 65 78 63 65 70 74 |ing-poin|t except|
|00005c80| 69 6f 6e 20 68 61 6e 64 | 6c 65 72 73 20 76 69 61 |ion hand|lers via|
|00005c90| 20 74 68 65 20 75 73 65 | 20 6f 66 20 74 68 65 20 | the use| of the |
|00005ca0| 54 72 61 70 56 65 63 74 | 6f 72 20 73 74 72 75 63 |TrapVect|or struc|
|00005cb0| 74 75 72 65 2e 20 54 68 | 65 20 72 65 6c 65 76 61 |ture. Th|e releva|
|00005cc0| 6e 74 20 69 6e 74 65 72 | 66 61 63 65 20 66 69 6c |nt inter|face fil|
|00005cd0| 65 73 20 66 6f 72 20 74 | 68 65 73 65 20 6f 70 65 |es for t|hese ope|
|00005ce0| 72 61 74 69 6f 6e 73 20 | 61 72 65 20 7b 43 49 6e |rations |are {CIn|
|00005cf0| 63 6c 75 64 65 73 7d 53 | 41 4e 45 2e 68 2c 20 7b |cludes}S|ANE.h, {|
|00005d00| 50 49 6e 74 65 72 66 61 | 63 65 73 7d 53 41 4e 45 |PInterfa|ces}SANE|
|00005d10| 2e 70 2c 20 61 6e 64 20 | 7b 46 49 6e 63 6c 75 64 |.p, and |{FInclud|
|00005d20| 65 73 7d 53 41 4e 45 2e | 66 2e 20 0d 41 20 54 72 |es}SANE.|f. .A Tr|
|00005d30| 61 70 56 65 63 74 6f 72 | 20 73 74 72 75 63 74 75 |apVector| structu|
|00005d40| 72 65 20 69 73 20 63 6f | 6d 70 6f 73 65 64 20 6f |re is co|mposed o|
|00005d50| 66 20 73 65 76 65 6e 20 | 34 2d 62 79 74 65 20 66 |f seven |4-byte f|
|00005d60| 69 65 6c 64 73 20 74 68 | 61 74 20 72 65 70 72 65 |ields th|at repre|
|00005d70| 73 65 6e 74 20 74 68 65 | 20 65 6e 74 72 79 2d 70 |sent the| entry-p|
|00005d80| 6f 69 6e 74 20 61 64 64 | 72 65 73 73 65 73 20 6f |oint add|resses o|
|00005d90| 66 20 74 68 65 20 75 73 | 65 72 d5 73 20 42 53 55 |f the us|er.s BSU|
|00005da0| 4e 2c 20 49 4e 45 58 2c | 20 44 5a 2c 20 55 4e 46 |N, INEX,| DZ, UNF|
|00005db0| 4c 2c 20 4f 50 45 52 52 | 2c 20 4f 56 46 4c 2c 20 |L, OPERR|, OVFL, |
|00005dc0| 61 6e 64 20 53 4e 41 4e | 20 65 78 63 65 70 74 69 |and SNAN| excepti|
|00005dd0| 6f 6e 20 68 61 6e 64 6c | 65 72 73 2c 20 72 65 73 |on handl|ers, res|
|00005de0| 70 65 63 74 69 76 65 6c | 79 2e 20 47 65 74 54 72 |pectivel|y. GetTr|
|00005df0| 61 70 56 65 63 74 6f 72 | 20 72 6f 75 74 69 6e 65 |apVector| routine|
|00005e00| 73 20 72 65 61 64 20 74 | 68 65 20 63 75 72 72 65 |s read t|he curre|
|00005e10| 6e 74 20 66 6c 6f 61 74 | 69 6e 67 2d 70 6f 69 6e |nt float|ing-poin|
|00005e20| 74 20 65 78 63 65 70 74 | 69 6f 6e 20 76 65 63 74 |t except|ion vect|
|00005e30| 6f 72 73 20 69 6e 74 6f | 20 61 20 54 72 61 70 56 |ors into| a TrapV|
|00005e40| 65 63 74 6f 72 20 73 74 | 72 75 63 74 75 72 65 2e |ector st|ructure.|
|00005e50| 20 49 6e 20 6f 72 64 65 | 72 20 74 6f 20 69 6e 73 | In orde|r to ins|
|00005e60| 74 61 6c 6c 20 74 68 65 | 69 72 20 6f 77 6e 20 65 |tall the|ir own e|
|00005e70| 78 63 65 70 74 69 6f 6e | 20 68 61 6e 64 6c 65 72 |xception| handler|
|00005e80| 73 2c 20 75 73 65 72 73 | 20 6d 75 73 74 20 66 69 |s, users| must fi|
|00005e90| 72 73 74 20 69 6e 69 74 | 69 61 6c 69 7a 65 20 61 |rst init|ialize a|
|00005ea0| 20 54 72 61 70 56 65 63 | 74 6f 72 20 73 74 72 75 | TrapVec|tor stru|
|00005eb0| 63 74 75 72 65 20 77 69 | 74 68 20 65 6e 74 72 79 |cture wi|th entry|
|00005ec0| 20 70 6f 69 6e 74 73 20 | 6f 66 20 74 68 65 69 72 | points |of their|
|00005ed0| 20 68 61 6e 64 6c 65 72 | 20 72 6f 75 74 69 6e 65 | handler| routine|
|00005ee0| 73 20 61 6e 64 20 74 68 | 65 6e 20 69 6e 76 6f 6b |s and th|en invok|
|00005ef0| 65 20 61 20 53 65 74 54 | 72 61 70 56 65 63 74 6f |e a SetT|rapVecto|
|00005f00| 72 20 72 6f 75 74 69 6e | 65 20 77 69 74 68 20 74 |r routin|e with t|
|00005f10| 68 61 74 20 73 74 72 75 | 63 74 75 72 65 20 61 73 |hat stru|cture as|
|00005f20| 20 74 68 65 20 6f 70 65 | 72 61 6e 64 2e 0d 47 65 | the ope|rand..Ge|
|00005f30| 74 54 72 61 70 56 65 63 | 74 6f 72 20 61 6e 64 20 |tTrapVec|tor and |
|00005f40| 53 65 74 54 72 61 70 56 | 65 63 74 6f 72 20 72 6f |SetTrapV|ector ro|
|00005f50| 75 74 69 6e 65 73 20 69 | 6e 76 6f 6c 76 65 20 70 |utines i|nvolve p|
|00005f60| 72 69 76 69 6c 65 67 65 | 64 20 6f 70 65 72 61 74 |rivilege|d operat|
|00005f70| 69 6f 6e 73 20 62 65 63 | 61 75 73 65 20 74 68 65 |ions bec|ause the|
|00005f80| 79 20 61 63 63 65 73 73 | 20 4d 6f 74 6f 72 6f 6c |y access| Motorol|
|00005f90| 61 20 6c 6f 77 2d 6d 65 | 6d 6f 72 79 20 76 65 63 |a low-me|mory vec|
|00005fa0| 74 6f 72 20 74 61 62 6c | 65 20 6c 6f 63 61 74 69 |tor tabl|e locati|
|00005fb0| 6f 6e 73 2e 20 46 6f 72 | 20 51 75 61 64 72 61 20 |ons. For| Quadra |
|00005fc0| 70 6c 61 74 66 6f 72 6d | 73 2c 20 74 68 65 20 73 |platform|s, the s|
|00005fd0| 69 74 75 61 74 69 6f 6e | 20 69 73 20 66 75 72 74 |ituation| is furt|
|00005fe0| 68 65 72 20 63 6f 6d 70 | 6c 69 63 61 74 65 64 20 |her comp|licated |
|00005ff0| 62 79 20 74 68 65 20 66 | 61 63 74 20 74 68 61 74 |by the f|act that|
|00006000| 20 66 69 76 65 20 6f 66 | 20 74 68 65 20 73 65 76 | five of| the sev|
|00006010| 65 6e 20 75 73 65 72 20 | 66 6c 6f 61 74 69 6e 67 |en user |floating|
|00006020| 2d 70 6f 69 6e 74 20 65 | 78 63 65 70 74 69 6f 6e |-point e|xception|
|00006030| 20 76 65 63 74 6f 72 73 | 20 61 72 65 20 73 74 6f | vectors| are sto|
|00006040| 72 65 64 20 62 79 20 74 | 68 65 20 73 79 73 74 65 |red by t|he syste|
|00006050| 6d 20 69 6e 20 73 65 63 | 6f 6e 64 61 72 79 20 6c |m in sec|ondary l|
|00006060| 6f 63 61 74 69 6f 6e 73 | 20 62 65 63 61 75 73 65 |ocations| because|
|00006070| 20 74 68 65 20 46 50 53 | 50 20 68 61 73 20 70 72 | the FPS|P has pr|
|00006080| 65 65 6d 70 74 65 64 20 | 74 68 65 20 6f 72 69 67 |eempted |the orig|
|00006090| 69 6e 61 6c 20 76 65 63 | 74 6f 72 20 74 61 62 6c |inal vec|tor tabl|
|000060a0| 65 20 6c 6f 63 61 74 69 | 6f 6e 73 2e 20 47 65 74 |e locati|ons. Get|
|000060b0| 54 72 61 70 56 65 63 74 | 6f 72 20 61 6e 64 20 53 |TrapVect|or and S|
|000060c0| 65 74 54 72 61 70 56 65 | 63 74 6f 72 20 69 6d 70 |etTrapVe|ctor imp|
|000060d0| 6c 65 6d 65 6e 74 61 74 | 69 6f 6e 73 20 63 69 72 |lementat|ions cir|
|000060e0| 63 75 6d 76 65 6e 74 20 | 74 68 65 73 65 20 64 69 |cumvent |these di|
|000060f0| 66 66 69 63 75 6c 74 69 | 65 73 20 62 79 20 63 61 |fficulti|es by ca|
|00006100| 6c 6c 69 6e 67 20 61 20 | 73 79 73 74 65 6d 20 75 |lling a |system u|
|00006110| 74 69 6c 69 74 79 2c 20 | 50 72 69 76 54 72 61 70 |tility, |PrivTrap|
|00006120| 2c 20 77 68 69 63 68 20 | 64 6f 65 73 20 61 6c 6c |, which |does all|
|00006130| 20 6f 66 20 74 68 65 20 | 77 6f 72 6b 20 6f 66 20 | of the |work of |
|00006140| 71 75 65 72 79 69 6e 67 | 20 6f 72 20 69 6e 73 74 |querying| or inst|
|00006150| 61 6c 6c 69 6e 67 20 74 | 68 65 20 75 73 65 72 d5 |alling t|he user.|
|00006160| 73 20 76 65 63 74 6f 72 | 73 2e 0d 54 68 65 20 50 |s vector|s..The P|
|00006170| 72 69 76 54 72 61 70 20 | 4d 65 63 68 61 6e 69 73 |rivTrap |Mechanis|
|00006180| 6d 0d 50 72 69 76 54 72 | 61 70 20 69 73 20 69 6d |m.PrivTr|ap is im|
|00006190| 70 6c 65 6d 65 6e 74 65 | 64 20 61 73 20 61 20 73 |plemente|d as a s|
|000061a0| 79 73 74 65 6d 20 74 72 | 61 70 2c 20 24 41 30 39 |ystem tr|ap, $A09|
|000061b0| 37 2e 20 55 70 6f 6e 20 | 65 6e 74 72 79 2c 20 69 |7. Upon |entry, i|
|000061c0| 74 20 65 78 70 65 63 74 | 73 20 61 20 73 65 6c 65 |t expect|s a sele|
|000061d0| 63 74 6f 72 20 76 61 6c | 75 65 20 69 6e 20 72 65 |ctor val|ue in re|
|000061e0| 67 69 73 74 65 72 20 44 | 30 2e 57 20 61 6e 64 20 |gister D|0.W and |
|000061f0| 61 20 54 72 61 70 56 65 | 63 74 6f 72 20 73 74 72 |a TrapVe|ctor str|
|00006200| 75 63 74 75 72 65 20 61 | 64 64 72 65 73 73 20 69 |ucture a|ddress i|
|00006210| 6e 20 61 64 64 72 65 73 | 73 20 72 65 67 69 73 74 |n addres|s regist|
|00006220| 65 72 20 41 30 2e 20 54 | 68 65 20 47 65 74 54 72 |er A0. T|he GetTr|
|00006230| 61 70 56 65 63 74 6f 72 | 20 6f 70 65 72 61 74 69 |apVector| operati|
|00006240| 6f 6e 20 72 65 71 75 69 | 72 65 73 20 61 20 73 65 |on requi|res a se|
|00006250| 6c 65 63 74 6f 72 20 76 | 61 6c 75 65 20 6f 66 20 |lector v|alue of |
|00006260| 31 3b 20 69 6e 20 74 68 | 69 73 20 63 61 73 65 2c |1; in th|is case,|
|00006270| 20 50 72 69 76 54 72 61 | 70 20 72 65 61 64 73 20 | PrivTra|p reads |
|00006280| 74 68 65 20 63 75 72 72 | 65 6e 74 20 66 6c 6f 61 |the curr|ent floa|
|00006290| 74 69 6e 67 2d 70 6f 69 | 6e 74 20 65 78 63 65 70 |ting-poi|nt excep|
|000062a0| 74 69 6f 6e 20 76 65 63 | 74 6f 72 73 20 69 6e 74 |tion vec|tors int|
|000062b0| 6f 20 74 68 65 20 54 72 | 61 70 56 65 63 74 6f 72 |o the Tr|apVector|
|000062c0| 20 73 74 72 75 63 74 75 | 72 65 20 61 74 20 28 41 | structu|re at (A|
|000062d0| 30 29 2e 20 54 68 65 20 | 73 65 6c 65 63 74 6f 72 |0). The |selector|
|000062e0| 20 76 61 6c 75 65 20 6f | 66 20 32 20 69 6e 76 6f | value o|f 2 invo|
|000062f0| 6b 65 73 20 74 68 65 20 | 53 65 74 54 72 61 70 56 |kes the |SetTrapV|
|00006300| 65 63 74 6f 72 20 6f 70 | 65 72 61 74 69 6f 6e 3b |ector op|eration;|
|00006310| 20 74 68 65 20 75 73 65 | 72 d5 73 20 65 78 63 65 | the use|r.s exce|
|00006320| 70 74 69 6f 6e 20 76 65 | 63 74 6f 72 73 20 69 6e |ption ve|ctors in|
|00006330| 20 74 68 65 20 54 72 61 | 70 56 65 63 74 6f 72 20 | the Tra|pVector |
|00006340| 73 74 72 75 63 74 75 72 | 65 20 61 74 20 28 41 30 |structur|e at (A0|
|00006350| 29 20 61 72 65 20 69 6e | 73 74 61 6c 6c 65 64 20 |) are in|stalled |
|00006360| 61 70 70 72 6f 70 72 69 | 61 74 65 6c 79 20 69 6e |appropri|ately in|
|00006370| 20 74 68 65 20 73 79 73 | 74 65 6d 2e 20 49 6e 20 | the sys|tem. In |
|00006380| 65 69 74 68 65 72 20 63 | 61 73 65 2c 20 72 65 67 |either c|ase, reg|
|00006390| 69 73 74 65 72 73 20 41 | 30 20 61 6e 64 20 41 31 |isters A|0 and A1|
|000063a0| 20 61 72 65 20 6d 6f 64 | 69 66 69 65 64 20 75 70 | are mod|ified up|
|000063b0| 6f 6e 20 65 78 69 74 2e | 0d 41 73 20 6f 66 20 74 |on exit.|.As of t|
|000063c0| 68 65 20 64 72 61 66 74 | 69 6e 67 20 6f 66 20 74 |he draft|ing of t|
|000063d0| 68 69 73 20 4e 6f 74 65 | 2c 20 6f 6e 6c 79 20 74 |his Note|, only t|
|000063e0| 68 65 20 51 75 61 64 72 | 61 20 61 6e 64 20 50 6f |he Quadr|a and Po|
|000063f0| 77 65 72 42 6f 6f 6b 20 | 31 37 30 20 70 6c 61 74 |werBook |170 plat|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.